// var xmlHttp=null;
var saturnJspTag = {Version:"1.3"};
saturnJspTag.Base = function () {
};
saturnJspTag.Base.prototype = {resolveParameters:function () {
	var qs = delimitQueryString(extractQueryString(this.url));
	if (this.options.parameters) {
		this.options.parameters += "," + qs;
	} else {
		this.options.parameters = qs;
	}
	this.url = trimQueryString(this.url);
	if ((this.options.parameters.length > 0) && (this.options.parameters.charAt(this.options.parameters.length - 1) === ",")) {
		this.options.parameters = this.options.parameters.substr(0, this.options.parameters.length - 1);
	}
}};
var direction01 = "horizontal";
var direction02 = "vertical";
var buttonSize = 4;
var buttonSize = 6;
var widthOrHeight = 7;
var PositionSize = 200;
var cursor01 = null;
var displayTdPart = null;
saturnJspTag.SplitPanelComponent = Class.create();
saturnJspTag.SplitPanelComponent.prototype = Object.extend(new saturnJspTag.Base(), {initialize:function (id, orientation1) {
	this.SplitPanelElement = document.getElementById(id);
	this.SplitPanelElement.orientation = orientation1;
	this.SplitPanelElement.Padding = 1;
	this.SplitPanelElement.showbuttons = true;
	this.SplitPanelElement.draggable = true;
	this.SplitPanelElement.Position = PositionSize;
}, destroy:function () {
	this.SplitPanelElement.splitPanelCell00 = null;
	if (this.SplitPanelElement.displayTdEle != null) {
		this.SplitPanelElement.displayTdEle.SplitPanel1Ele = null;
	}
	this.SplitPanelElement.displayTdEle = null;
	this.SplitPanelElement.IMG1Element = null;
	this.SplitPanelElement.IMGForButton2 = null;
	this.SplitPanelElement.splitPanelCell = null;
}, getOrientation:function () {
	return this.SplitPanelElement.orientation;
}, getPadding:function () {
	return this.SplitPanelElement.Padding;
}, setPadding:function (padding) {
	this.SplitPanelElement.Padding = padding;
}, isShowButtons:function () {
	return this.SplitPanelElement.showbuttons;
}, setShowButtons:function (showButtons) {
	this.SplitPanelElement.showbuttons = showButtons;
}, isDraggable:function () {
	return this.SplitPanelElement.draggable;
}, setDraggable:function (Draggable) {
	this.SplitPanelElement.draggable = Draggable;
}, getPosition:function () {
	return this.SplitPanelElement.Position;
}, setPosition:function (position) {
	this.SplitPanelElement.Position = position;
	if (this.SplitPanelElement.splitPanelCell00) {
		if (this.SplitPanelElement.orientation == direction02) {
			if (position == "100%") {
				this.SplitPanelElement.Status = 1;
				this.SplitPanelElement.splitPanelCell.style.height = 0;
			} else {
				if (position == 0) {
					this.SplitPanelElement.Status = 2;
					this.SplitPanelElement.splitPanelCell.style.height = "100%";
				} else {
					this.SplitPanelElement.Status = 0;
					this.SplitPanelElement.splitPanelCell.style.height = "";
				}
			}
			this.SplitPanelElement.splitPanelCell00.style.height = position;
		} else {
			if (position == "100%") {
				this.SplitPanelElement.Status = 1;
				this.SplitPanelElement.splitPanelCell.style.width = 0;
			} else {
				if (position == 0) {
					this.SplitPanelElement.Status = 2;
					this.SplitPanelElement.splitPanelCell.style.width = "100%";
				} else {
					this.SplitPanelElement.Status = 0;
					this.SplitPanelElement.splitPanelCell.style.width = "";
				}
			}
			this.SplitPanelElement.splitPanelCell00.style.width = position;
		}
		if (this.SplitPanelElement.showbuttons) {
			if (position == 0) {
				this.SplitPanelElement.IMG1Element.Disabled = true;
				this.SplitPanelElement.IMGForButton2.Disabled = false;
			} else {
				if (position == "100%") {
					this.SplitPanelElement.IMG1Element.Disabled = false;
					this.SplitPanelElement.IMGForButton2.Disabled = true;
				} else {
					this.SplitPanelElement.IMG1Element.Disabled = false;
					this.SplitPanelElement.IMGForButton2.Disabled = false;
				}
			}
			var src, ButtonElement;
			ButtonElement = this.SplitPanelElement.IMG1Element;
			src = (ButtonElement.Disabled) ? ButtonElement.skinPath2 : ButtonElement.skinPath1;
			if (ButtonElement.src != src) {
				ButtonElement.src = src;
			}
			ButtonElement = this.SplitPanelElement.IMGForButton2;
			src = (ButtonElement.Disabled) ? ButtonElement.skinPath2 : ButtonElement.skinPath1;
			if (ButtonElement.src != src) {
				ButtonElement.src = src;
			}
		}
		excuteResize();
	}
}, init:function (split) {
	function buttonComponent(SplitPanelElement) {
		var ButtonElement = document.createElement("IMG");
		setControlClassName(ButtonElement, SplitPanelElement.ElementClassName + "_Button");
		EventManager.addSystemEvent(ButtonElement, "onclick", function (event) {
			split.onclickSplitPanel1(SplitPanelElement, ButtonElement, event, split);
		});
		return ButtonElement;
	}
	function createSplitPanel(SplitPanelElement) {
		var TableElement = document.createElement("TABLE");
		TableElement.cellPadding = 0;
		TableElement.cellSpacing = 0;
		var TbodyElement = document.createElement("TBODY");
		var TrElement, TdElement;
		setControlClassName(TableElement, SplitPanelElement.ElementClassName + "_ButtonArea");
		if (SplitPanelElement.orientation == direction02) {
			TrElement = document.createElement("TR");
			TdElement = document.createElement("TD");
			TdElement.style.width = 6;
			TrElement.appendChild(TdElement);
			TdElement = document.createElement("TD");
			TrElement.appendChild(TdElement);
			var IMGElement5 = buttonComponent(SplitPanelElement);
			IMGElement5._saturnClass = "ButtonClass";
			IMGElement5.skinPath1 = __SKIN_PATH + "/splitpanel_button_vert1.gif";
			IMGElement5.skinPath2 = __SKIN_PATH + "/splitpanel_button_vert1_disabled.gif";
			IMGElement5.style.width = widthOrHeight;
			SplitPanelElement.IMG1Element = IMGElement5;
			TdElement.appendChild(IMGElement5);
			TdElement = document.createElement("TD");
			TdElement.style.width = 6;
			TrElement.appendChild(TdElement);
			TdElement = document.createElement("TD");
			var IMGElement6 = buttonComponent(SplitPanelElement);
			IMGElement6._saturnClass = "IMGClass";
			IMGElement6.skinPath1 = __SKIN_PATH + "/splitpanel_button_vert2.gif";
			IMGElement6.skinPath2 = __SKIN_PATH + "/splitpanel_button_vert2_disabled.gif";
			IMGElement6.style.width = widthOrHeight;
			SplitPanelElement.IMGForButton2 = IMGElement6;
			TdElement.appendChild(IMGElement6);
			TrElement.appendChild(TdElement);
			TdElement = document.createElement("TD");
			TdElement.style.width = 6;
			TrElement.appendChild(TdElement);
			TbodyElement.appendChild(TrElement);
		} else {
			TrElement = document.createElement("TR");
			TrElement.style.height = 6;
			TdElement = document.createElement("TD");
			TrElement.appendChild(TdElement);
			TbodyElement.appendChild(TrElement);
			TrElement = document.createElement("TR");
			TdElement = document.createElement("TD");
			var IMGElement5 = buttonComponent(SplitPanelElement);
			IMGElement5.skinPath1 = __SKIN_PATH + "/splitpanel_button_hori1.gif";
			IMGElement5.skinPath2 = __SKIN_PATH + "/splitpanel_button_hori1_disabled.gif";
			IMGElement5._saturnClass = "ButtonClass";
			IMGElement5.style.height = widthOrHeight;
			SplitPanelElement.IMG1Element = IMGElement5;
			TdElement.appendChild(IMGElement5);
			TrElement.appendChild(TdElement);
			TbodyElement.appendChild(TrElement);
			TrElement = document.createElement("TR");
			TrElement.style.height = 6;
			TdElement = document.createElement("TD");
			TrElement.appendChild(TdElement);
			TbodyElement.appendChild(TrElement);
			TrElement = document.createElement("TR");
			TdElement = document.createElement("TD");
			var IMGElement6 = buttonComponent(SplitPanelElement);
			IMGElement6._saturnClass = "IMGClass";
			IMGElement6.skinPath1 = __SKIN_PATH + "/splitpanel_button_hori2.gif";
			IMGElement6.skinPath2 = __SKIN_PATH + "/splitpanel_button_hori2_disabled.gif";
			IMGElement6.style.height = widthOrHeight;
			SplitPanelElement.IMGForButton2 = IMGElement6;
			TdElement.appendChild(IMGElement6);
			TrElement.appendChild(TdElement);
			TbodyElement.appendChild(TrElement);
			TrElement = document.createElement("TR");
			TrElement.style.height = 6;
			TdElement = document.createElement("TD");
			TrElement.appendChild(TdElement);
			TbodyElement.appendChild(TrElement);
		}
		TableElement.appendChild(TbodyElement);
		EventManager.addSystemEvent(TableElement, "onmousedown", function (event) {
			event.cancelBubble = true;
		});
		return TableElement;
	}
	function setSplitPanelCss(SplitPanelElement) {
		var TableElement = document.createElement("TABLE");
		setControlClassName(TableElement, SplitPanelElement.ElementClassName + "_Splitter");
		TableElement.cellPadding = 0;
		TableElement.cellSpacing = 0;
		TableElement.style.width = "100%";
		TableElement.style.height = "100%";
		TableElement.border = getPreferenceSetting("__SplitPanel_Splitter_BorderWidth");
		TableElement.borderColor = getPreferenceSetting("__SplitPanel_Splitter_BorderColor");
		var TbodyElement = document.createElement("TBODY");
		var TrElement = document.createElement("TR");
		var TdElement = document.createElement("TD");
		TdElement.align = "center";
		TdElement.valign = "center";
		if (SplitPanelElement.showbuttons) {
			TdElement.appendChild(createSplitPanel(SplitPanelElement));
		}
		TrElement.appendChild(TdElement);
		TbodyElement.appendChild(TrElement);
		TableElement.appendChild(TbodyElement);
		return TableElement;
	}
	this.SplitPanelElement.cellPadding = this.SplitPanelElement.Padding;
	this.SplitPanelElement.cellSpacing = 0;
	this.SplitPanelElement.style.tableLayout = "fixed";
	var TbodyElement = this.SplitPanelElement.tBodies[0];
	var cell00, cell20, cell10, displayTdElement;
	var size = (this.SplitPanelElement.showbuttons) ? buttonSize : buttonSize;
	if (this.SplitPanelElement.orientation == direction02) {
		if (!this.SplitPanelElement.className) {
			this.SplitPanelElement.className = "SplitPanel_Vert";
		}
		this.SplitPanelElement.ElementClassName = this.SplitPanelElement.className;
		cell00 = TbodyElement.rows[0].cells[0];
		this.SplitPanelElement.splitPanelCell00 = cell00;
		displayTdElement = setSplitPanelCss(this.SplitPanelElement);
		cell10 = TbodyElement.rows[1].cells[0];
		cell10.style.height = size + this.SplitPanelElement.Padding * 2;
		cell10.appendChild(displayTdElement);
		if (this.SplitPanelElement.draggable) {
			displayTdElement.style.cursor = "n-resize";
		}
		this.SplitPanelElement.displayTdEle = displayTdElement;
		cell20 = TbodyElement.rows[2].cells[0];
		this.SplitPanelElement.splitPanelCell = cell20;
	} else {
		if (!this.SplitPanelElement.className) {
			this.SplitPanelElement.className = "SplitPanel_Hori";
		}
		this.SplitPanelElement.ElementClassName = this.SplitPanelElement.className;
		cell00 = TbodyElement.rows[0].cells[0];
		this.SplitPanelElement.splitPanelCell00 = cell00;
		displayTdElement = setSplitPanelCss(this.SplitPanelElement);
		cell10 = TbodyElement.rows[0].cells[1];
		cell10.style.width = size + this.SplitPanelElement.Padding * 2;
		cell10.appendChild(displayTdElement);
		if (this.SplitPanelElement.draggable) {
			displayTdElement.style.cursor = "e-resize";
		}
		this.SplitPanelElement.displayTdEle = displayTdElement;
		cell20 = TbodyElement.rows[0].cells[2];
		this.SplitPanelElement.splitPanelCell = cell20;
	}
	cell00.vAlign = "top";
	cell20.vAlign = "top";
	cell20.style.width = "100%";
	cell20.style.height = "100%";
	displayTdElement.SplitPanel1Ele = this.SplitPanelElement;
	EventManager.addSystemEvent(displayTdElement, "onclick", function (event) {
		split.onclickSplitPanel(displayTdElement, event, split);
	});
	EventManager.addSystemEvent(displayTdElement, "onmousemove", function (event) {
		split.onmousemoveSplitPanel(displayTdElement, event, split);
	});
	EventManager.addSystemEvent(displayTdElement, "onmousedown", function (event) {
		split.onmousedownSplitPanel(displayTdElement, event, split);
		event.returnValue = false;
		event.cancelBubble = true;
	});
	if (browserType == browserType1) {
		EventManager.addSystemEvent(displayTdElement, "onmouseup", function (event) {
			split.onmouseupSplitPanel(displayTdElement, event, split);
		});
	}
}, getCursor:function () {
	var cursor = cursor01;
	if (cursor == null) {
		cursor = document.createElement("IMG");
		setComponentVisible(cursor, false);
		setControlClassName(cursor, this.SplitPanelElement.ElementClassName + "_DraggingCursor");
		document.body.appendChild(cursor);
		cursor01 = cursor;
	}
	cursor.style.zIndex = getzIndex();
	return cursor;
}, setCursor:function (event) {
	var x, y;
	if (browserType == browserType1) {
		x = event.clientX + document.body.scrollLeft;
		y = event.clientY + document.body.scrollTop;
	} else {
		x = event.pageX;
		y = event.pageY;
	}
	var cursor = this.getCursor();
	var absolutePosition = getAbsolutePosition(this.SplitPanelElement.displayTdEle);
	var absolutePosition00 = getAbsolutePosition(this.SplitPanelElement);
	if (this.SplitPanelElement.orientation == direction02) {
		var top = absolutePosition[1] + (y - this.SplitPanelElement.positionY);
		if (top >= absolutePosition00[1] && top <= absolutePosition00[1] + this.SplitPanelElement.offsetHeight) {
			cursor.style.top = top;
		}
	} else {
		var left = absolutePosition[0] + (x - this.SplitPanelElement.positionX);
		if (left >= absolutePosition00[0] && left <= absolutePosition00[0] + this.SplitPanelElement.offsetWidth) {
			cursor.style.left = left;
		}
	}
}, onclickSplitPanel:function (displayTdElement, event, split) {
	var SplitPanelElement = displayTdElement.SplitPanel1Ele;
	if (SplitPanelElement.orientation == direction02) {
		if (SplitPanelElement.Status == 2) {
			split.setPosition(SplitPanelElement.subStylePositionWidth);
		} else {
			SplitPanelElement.subStylePositionWidth = SplitPanelElement.splitPanelCell00.offsetHeight;
			split.setPosition(0);
		}
	} else {
		if (SplitPanelElement.Status == 2) {
			split.setPosition(SplitPanelElement.subStylePositionWidth);
		} else {
			SplitPanelElement.subStylePositionWidth = SplitPanelElement.splitPanelCell00.offsetWidth;
			split.setPosition(0);
		}
	}
	if (browserType == browserType1) {
		displayTdElement.releaseCapture();
	} else {
		EventManager.removeSystemEvent(window, "onmousemove", onmouseoverforSplitPanel, true);
		EventManager.removeSystemEvent(window, "onmouseup", onmouseupforSplitPanel, true);
		displayTdPart = null;
	}
	SplitPanelElement.positionX = -1;
	SplitPanelElement.positionY = -1;
	SplitPanelElement.positionflag = false;
}, onmousemoveSplitPanel:function (displayTdElement, event) {
	var SplitPanelElement = displayTdElement.SplitPanel1Ele;
	if (SplitPanelElement.positionflag) {
		this.setCursor(event);
	} else {
		var x, y;
		if (browserType == browserType1) {
			x = event.clientX + document.body.scrollLeft;
			y = event.clientY + document.body.scrollTop;
		} else {
			x = event.pageX;
			y = event.pageY;
		}
		if (SplitPanelElement.positionX >= 0 && SplitPanelElement.positionY >= 0 && (Math.abs(SplitPanelElement.positionX - x) > 2 || Math.abs(SplitPanelElement.positionY - y) > 2)) {
			if (browserType != browserType1) {
				setComponentDisplay(getDIVForSplitPanel(), true);
			}
			var cursor = this.getCursor();
			var absolutePosition = getAbsolutePosition(displayTdElement);
			cursor.style.left = absolutePosition[0];
			cursor.style.top = absolutePosition[1];
			cursor.style.width = displayTdElement.offsetWidth;
			cursor.style.height = displayTdElement.offsetHeight;
			setComponentVisible(cursor, true);
			SplitPanelElement.positionflag = true;
		}
	}
}, onmousedownSplitPanel:function (displayTdElement, event) {
	var SplitPanelElement = displayTdElement.SplitPanel1Ele;
	if (!SplitPanelElement.draggable) {
		return;
	}
	var whichbutton;
	var target;
	if (browserType == browserType1) {
		whichbutton = event.button;
		target = event.srcElement;
		target.unselectable = true;
	} else {
		whichbutton = event.which;
		target = event.target;
		target.style.MozUserSelect = "none";
	}
	if (whichbutton != 1) {
		return;
	}
	if (!SplitPanelElement.positionflag) {
		var x, y;
		if (browserType == browserType1) {
			x = event.clientX + document.body.scrollLeft;
			y = event.clientY + document.body.scrollTop;
			displayTdElement.setCapture(true);
		} else {
			x = event.pageX;
			y = event.pageY;
			displayTdPart = displayTdElement;
			EventManager.addSystemEvent(window, "onmousemove", onmouseoverforSplitPanel, true);
			EventManager.addSystemEvent(window, "onmouseup", onmouseupforSplitPanel, true);
		}
		SplitPanelElement.positionX = x;
		SplitPanelElement.positionY = y;
	}
}, onmouseupSplitPanel:function (displayTdElement, event, split) {
	var whichbutton;
	if (browserType == browserType1) {
		whichbutton = event.button;
	} else {
		whichbutton = event.which;
	}
	if (whichbutton != 1) {
		return;
	}
	var SplitPanelElement = displayTdElement.SplitPanel1Ele;
	if (!SplitPanelElement.positionflag) {
		return;
	}
	var x, y;
	if (browserType == browserType1) {
		x = event.clientX + document.body.scrollLeft;
		y = event.clientY + document.body.scrollTop;
	} else {
		x = event.pageX;
		y = event.pageY;
	}
	var cell00 = SplitPanelElement.splitPanelCell00;
	var absolutePosition = getAbsolutePosition(displayTdElement);
	if (SplitPanelElement.orientation == direction02) {
		var height = cell00.offsetHeight + (y - SplitPanelElement.positionY);
		if (height >= 0 && height <= SplitPanelElement.offsetHeight) {
			split.setPosition(height);
		}
	} else {
		var width = cell00.offsetWidth + (x - SplitPanelElement.positionX);
		if (width >= 0 && width <= SplitPanelElement.offsetWidth) {
			split.setPosition(width);
		}
	}
	var cursor = this.getCursor();
	setComponentVisible(cursor, false);
	if (browserType == browserType1) {
		displayTdElement.releaseCapture();
	} else {
		EventManager.removeSystemEvent(window, "onmousemove", onmouseoverforSplitPanel, true);
		EventManager.removeSystemEvent(window, "onmouseup", onmouseupforSplitPanel, true);
		displayTdPart = null;
		if (browserType != browserType1) {
			setComponentDisplay(getDIVForSplitPanel(), false);
		}
	}
	SplitPanelElement.positionX = -1;
	SplitPanelElement.positionY = -1;
	SplitPanelElement.positionflag = false;
}, onclickSplitPanel1:function (SplitPanelElement, ButtonElement, event, split) {
	if (SplitPanelElement.orientation == direction02) {
		if (ButtonElement._saturnClass == "ButtonClass") {
			if (SplitPanelElement.splitPanelCell.offsetHeight <= 1) {
				split.setPosition(SplitPanelElement.subStylePositionWidth);
			} else {
				if (SplitPanelElement.splitPanelCell00.offsetHeight > 1) {
					SplitPanelElement.subStylePositionWidth = SplitPanelElement.splitPanelCell00.offsetHeight;
					split.setPosition(0);
				}
			}
		} else {
			if (SplitPanelElement.splitPanelCell00.offsetHeight <= 1) {
				split.setPosition(SplitPanelElement.subStylePositionWidth);
			} else {
				if (SplitPanelElement.splitPanelCell.offsetHeight > 1) {
					SplitPanelElement.subStylePositionWidth = SplitPanelElement.splitPanelCell00.offsetHeight;
					split.setPosition("100%");
				}
			}
		}
	} else {
		if (ButtonElement._saturnClass == "ButtonClass") {
			if (SplitPanelElement.splitPanelCell.offsetWidth <= 1) {
				split.setPosition(SplitPanelElement.subStylePositionWidth);
			} else {
				if (SplitPanelElement.splitPanelCell00.offsetWidth > 1) {
					SplitPanelElement.subStylePositionWidth = SplitPanelElement.splitPanelCell00.offsetWidth;
					split.setPosition(0);
				}
			}
		} else {
			if (SplitPanelElement.splitPanelCell00.offsetWidth <= 1) {
				split.setPosition(SplitPanelElement.subStylePositionWidth);
			} else {
				if (SplitPanelElement.splitPanelCell.offsetWidth > 1) {
					SplitPanelElement.subStylePositionWidth = SplitPanelElement.splitPanelCell00.offsetWidth;
					split.setPosition("100%");
				}
			}
		}
	}
	event.cancelBubble = true;
}, onmouseupforSplitPanel:function (event) {
	onmouseupSplitPanel(displayTdPart, event);
}, onmouseoverforSplitPanel:function (event) {
	onmousemoveSplitPanel(displayTdPart, event);
}});
var collection00 = new Collection();
var DIVElementSubWindow00 = null;
function initSubWindow() {
	if (DIVElementSubWindow00 == null) {
		var DIVElement = document.createElement("DIV");
		DIVElement.className = "ExclusiveCovering";
		DIVElement.style.position = "absolute";
		DIVElement.style.left = 0;
		DIVElement.style.top = 0;
		DIVElement.style.display = "none";
		document.body.appendChild(DIVElement);
		DIVElementSubWindow00 = DIVElement;
	}
	var scrollWidth = document.body.scrollWidth;
	var scrollHeight = document.body.scrollHeight;
	var clientWidth = document.body.clientWidth;
	var clientHeight = document.body.clientHeight;
	DIVElementSubWindow00.style.width = (scrollWidth > clientWidth) ? scrollWidth : clientWidth;
	DIVElementSubWindow00.style.height = (scrollHeight > clientHeight) ? scrollHeight : clientHeight;
	DIVElementSubWindow00.style.zIndex = getzIndex();
	return DIVElementSubWindow00;
}
var subWindowStatus00 = "normal";
var subWindowStatus01 = "minimize";
var subWindowStatus02 = "maximize";
var subWindowStatus03 = "hidden";
var SubWindow = new Object();
var subWindowTemp = null;
var subwindowCousor = null;
saturnJspTag.SubWindowComponent = Class.create();
saturnJspTag.SubWindowComponent.prototype = Object.extend(new saturnJspTag.Base(), {initialize:function (id, status) {
	this.SubWindowElement = document.getElementById(id);
	this.SubWindowElement.Title = "";
	this.SubWindowElement.Resizable = true;
	this.SubWindowElement.draggable = true;
	this.SubWindowElement.showminimizebutton = true;
	this.SubWindowElement.showmaxnimizebutton = true;
	this.SubWindowElement.showclosebutton = true;
	this.SubWindowElement.titleclickaction = null;
	this.SubWindowElement.titledblclickaction = "maximize";
	this.SubWindowElement.Status = (status) ? status : subWindowStatus00;
	this.SubWindowElement.styleCss = false;
	this.SubWindowElement.hasExpanded = false;
	collection00.insert(this.SubWindowElement);
}, activate:function (subWin) {
	if (!this.SubWindowElement.uMap02) {
		if (this.SubWindowElement.Status != subWindowStatus01 && this.SubWindowElement.Status != subWindowStatus03) {
			if (typeof (this.SubWindowElement._initChildren) == "function") {
				this.SubWindowElement._initChildren();
				this.SubWindowElement._initChildren = null;
			}
		}
		this.rebuild(subWin);
		if (this.SubWindowElement.Status != subWindowStatus00) {
			var status = this.SubWindowElement.Status;
			this.SubWindowElement.Status = subWindowStatus00;
			this.setStatus(status);
		}
		this.SubWindowElement.uMap02 = true;
		this.refresh();
	}
}, rebuild:function (subWin) {
	EventManager.addSystemEvent(this.SubWindowElement, "onmousemove", function (event) {
		subWin.onmousemoveSubWindow(SubWindowElement, event, subWin);
	});
	EventManager.addSystemEvent(this.SubWindowElement, "onmousedown", function (event) {
		subWin.onmousedownSubWindow(SubWindowElement, event, subWin);
	});
	if (browserType == browserType1) {
		EventManager.addSystemEvent(this.SubWindowElement, "onmouseup", function (event) {
			subWin.onmouseupSubWindow(SubWindowElement, event, subWin);
		});
	}
	this.SubWindowElement.ElementClassName = this.SubWindowElement.className;
	if (!this.SubWindowElement.ElementClassName) {
		this.SubWindowElement.ElementClassName = "SubWindow";
	}
	if (this.SubWindowElement.style.position == "absolute") {
		setControlClassName(this.SubWindowElement, "Float" + this.SubWindowElement.ElementClassName);
	} else {
		setControlClassName(this.SubWindowElement, this.SubWindowElement.ElementClassName);
	}
	this.SubWindowElement.style.cursor = "move";
	var TableElement = this.SubWindowElement.firstChild;
	this.SubWindowElement.subwindowTable = TableElement;
	TableElement.style.cursor = "default";
	TableElement.className = "WindowTable";
	TableElement.style.width = "100%";
	TableElement.style.height = "100%";
	TableElement.cellPadding = 0;
	TableElement.cellSpacing = 0;
	TableElement.style.tableLayout = "fixed";
	var TbodyElement = this.SubWindowElement.firstChild.tBodies[0];
	var TrElement, TdElement;
	TrElement = TbodyElement.rows[0];
	TdElement = TrElement.cells[0];
	var TableElement1 = document.createElement("TABLE");
	TableElement1.cellPadding = 0;
	TableElement1.cellSpacing = 0;
	TableElement1.style.width = "100%";
	var TbodyElement1, TrElement1, TdElement1;
	TrElement1 = document.createElement("TR");
	TdElement1 = document.createElement("TD");
	TdElement1.innerHTML = this.SubWindowElement.Title;
	TdElement1.style.whiteSpace = "nowrap";
	TdElement1.style.paddingLeft = 8;
	TdElement1.style.width = "100%";
	TrElement1.appendChild(TdElement1);
	EventManager.addSystemEvent(TdElement1, "onclick", function (event) {
		subWin.onclickSubWindow02(this.SubWindowElement, event, subWin);
	});
	EventManager.addSystemEvent(TdElement1, "ondblclick", function (event) {
		subWin.ondblclickSubWindow02(this.SubWindowElement, event, subWin);
	});
	this.SubWindowElement.subwindowTd = TdElement1;
	var SubWindowElement = this.SubWindowElement;
	if (this.SubWindowElement.showminimizebutton) {
		TdElement1 = document.createElement("TD");
		var IMGElement = document.createElement("IMG");
		IMGElement._saturnClass = "WindowButton";
		IMGElement.className = "WindowButton";
		IMGElement.src = __SKIN_PATH + "/subwindow_minimize.gif";
		TdElement1.appendChild(IMGElement);
		TrElement1.appendChild(TdElement1);
		this.SubWindowElement.subwindowIMG = IMGElement;
		EventManager.addSystemEvent(IMGElement, "onmouseover", function (event) {
			subWin.onmouseoverSubWindow01(IMGElement, event, subWin);
		});
		EventManager.addSystemEvent(IMGElement, "onmouseout", function (event) {
			subWin.onmouseoutSubWindow01(IMGElement, event, subWin);
		});
		EventManager.addSystemEvent(IMGElement, "onclick", function (event) {
			subWin.onclickSubWindow01(SubWindowElement, IMGElement, event, subWin);
		});
	}
	if (this.SubWindowElement.showmaxnimizebutton) {
		TdElement1 = document.createElement("TD");
		var IMGElement1 = document.createElement("IMG");
		IMGElement1._saturnClass = "WindowButton";
		IMGElement1.className = "WindowButton";
		IMGElement1.src = __SKIN_PATH + "/subwindow_maximize.gif";
		TdElement1.appendChild(IMGElement1);
		TrElement1.appendChild(TdElement1);
		this.SubWindowElement.subwindowIMG1 = IMGElement1;
		EventManager.addSystemEvent(IMGElement1, "onmouseover", function (event) {
			subWin.onmouseoverSubWindow01(IMGElement1, event, subWin);
		});
		EventManager.addSystemEvent(IMGElement1, "onmouseout", function (event) {
			subWin.onmouseoutSubWindow01(IMGElement1, event, subWin);
		});
		EventManager.addSystemEvent(IMGElement1, "onclick", function (event) {
			subWin.onclickSubWindow03(SubWindowElement, IMGElement1, event, subWin);
		});
	}
	if (this.SubWindowElement.showclosebutton) {
		TdElement1 = document.createElement("TD");
		var IMGElement2 = document.createElement("IMG");
		IMGElement2._saturnClass = "WindowButton";
		IMGElement2.className = "WindowButton";
		IMGElement2.src = __SKIN_PATH + "/subwindow_close.gif";
		TdElement1.appendChild(IMGElement2);
		TrElement1.appendChild(TdElement1);
		this.SubWindowElement.subButton = IMGElement2;
		EventManager.addSystemEvent(IMGElement2, "onmouseover", function (event) {
			subWin.onmouseoverSubWindow01(IMGElement2, event, subWin);
		});
		EventManager.addSystemEvent(IMGElement2, "onmouseout", function (event) {
			subWin.onmouseoutSubWindow01(IMGElement2, event, subWin);
		});
		EventManager.addSystemEvent(IMGElement2, "onclick", function (event) {
			subWin.onclickhidesubwindow(SubWindowElement, IMGElement2, event, subWin);
		});
	}
	TbodyElement1 = document.createElement("TBODY");
	TbodyElement1.appendChild(TrElement1);
	TableElement1.appendChild(TbodyElement1);
	TdElement.className = "TitleBar";
	TdElement.appendChild(TableElement1);
	this.SubWindowElement.subTd = TdElement;
	TrElement = TbodyElement.rows[1];
	TrElement.style.height = "100%";
	TdElement = TrElement.cells[0];
	TdElement.style.padding = 2;
	var DIVElement = TdElement.childNodes[0];
	DIVElement.style.width = "100%";
	DIVElement.style.height = "100%";
	DIVElement.style.valign = "top";
	setControlClassName(DIVElement, this.SubWindowElement.ElementClassName + "$6O");
	this.SubWindowElement.contentcontainer = DIVElement;
	this.SubWindowElement.TdElement6 = TdElement;
	this.SubWindowElement.winFlag = true;
}, setClassName:function (stylePosition) {
	if (stylePosition) {
		setControlClassName(this.SubWindowElement, "Float" + this.SubWindowElement.ElementClassName);
		setControlClassName(this.SubWindowElement.contentcontainer, "Float" + this.SubWindowElement.ElementClassName + "$6O");
	} else {
		setControlClassName(this.SubWindowElement, this.SubWindowElement.ElementClassName);
		setControlClassName(this.SubWindowElement.contentcontainer, this.SubWindowElement.ElementClassName + "$6O");
	}
}, refresh:function () {
	this.setClassName(this.SubWindowElement.style.position == "absolute");
}, destroy:function () {
	collection00.remove(this.SubWindowElement);
	this.SubWindowElement.subwindowIMG = null;
	this.SubWindowElement.subwindowIMG1 = null;
	this.SubWindowElement.subButton = null;
	this.SubWindowElement.subwindowTd = null;
	this.SubWindowElement.subTd = null;
	this.SubWindowElement.contentcontainer = null;
	this.SubWindowElement.TdElement6 = null;
	this.SubWindowElement.subwindowTable = null;
	this.SubWindowElement.subWindowDIV = null;
}, getTitle:function () {
	return this.SubWindowElement.Title;
}, setTitle:function (title) {
	this.SubWindowElement.Title = title;
	if (this.SubWindowElement.uMap02) {
		this.SubWindowElement.subwindowTd.innerHTML = title;
	}
}, isResizable:function () {
	return this.SubWindowElement.Resizable;
}, setResizable:function (resizable) {
	this.SubWindowElement.Resizable = resizable;
	var DragMode;
	if (this.SubWindowElement.$t6 || this.SubWindowElement.draggable) {
		DragMode = "move";
	} else {
		DragMode = "default";
	}
	if (this.SubWindowElement.style.cursor != DragMode) {
		this.SubWindowElement.style.cursor = DragMode;
	}
}, isDraggable:function () {
	return this.SubWindowElement.draggable;
}, setDraggable:function (Draggable) {
	this.SubWindowElement.draggable = Draggable;
	var DragMode;
	if (this.SubWindowElement.$t6 || this.SubWindowElement.draggable) {
		DragMode = "move";
	} else {
		DragMode = "default";
	}
	if (this.SubWindowElement.style.cursor != DragMode) {
		this.SubWindowElement.style.cursor = DragMode;
	}
}, isShowMinimizeButton:function () {
	return this.SubWindowElement.showminimizebutton;
}, setShowMinimizeButton:function (showMinimizeButton) {
	this.SubWindowElement.showminimizebutton = showMinimizeButton;
}, isShowMaxnimizeButton:function () {
	return this.SubWindowElement.showmaxnimizebutton;
}, setShowMaximizeButton:function (showMaxnimizeButton) {
	this.SubWindowElement.showmaxnimizebutton = showMaxnimizeButton;
}, isShowCloseButton:function () {
	return this.SubWindowElement.showclosebutton;
}, setShowCloseButton:function (showCloseButton) {
	this.SubWindowElement.showclosebutton = showCloseButton;
}, getTitleClickAction:function () {
	return this.SubWindowElement.titleclickaction;
}, setTitleClickAction:function (titleClickAction) {
	this.SubWindowElement.titleclickaction = titleClickAction;
}, getTitleDblClickAction:function () {
	return this.SubWindowElement.titledblclickaction;
}, setTitleDblClickAction:function (titleDblClickAction) {
	this.SubWindowElement.titledblclickaction = titleDblClickAction;
}, getContentContainer:function () {
	return this.SubWindowElement.contentcontainer;
}, subWindowResizeProperties:function (event) {
	var x, y;
	if (browserType == browserType1) {
		x = event.clientX + document.body.scrollLeft;
		y = event.clientY + document.body.scrollTop;
	} else {
		x = event.pageX;
		y = event.pageY;
	}
	if (this.SubWindowElement.Resizable) {
		var absolutePosition = getAbsolutePosition(this.SubWindowElement);
		var left = absolutePosition[0] + 1;
		var top = absolutePosition[1] + 1;
		var de = Math.abs(left - x);
		var dw = Math.abs(left + this.SubWindowElement.offsetWidth - x);
		var dn = Math.abs(top - y);
		var ds = Math.abs(top + this.SubWindowElement.offsetHeight - y);
		if (de <= 3) {
			if (dn <= 18) {
				return "ne-resize";
			} else {
				if (ds <= 18) {
					return "se-resize";
				} else {
					return "e-resize";
				}
			}
		} else {
			if (dw <= 3) {
				if (dn <= 18) {
					return "nw-resize";
				} else {
					if (ds <= 18) {
						return "sw-resize";
					} else {
						return "w-resize";
					}
				}
			}
		}
		if (dn <= 3) {
			if (de <= 18) {
				return "ne-resize";
			} else {
				if (dw <= 18) {
					return "nw-resize";
				} else {
					return "n-resize";
				}
			}
		} else {
			if (ds <= 3) {
				if (de <= 18) {
					return "se-resize";
				} else {
					if (dw <= 18) {
						return "sw-resize";
					} else {
						return "s-resize";
					}
				}
			}
		}
	}
	if (this.SubWindowElement.draggable) {
		var TdElement1 = this.SubWindowElement.subwindowTd;
		var absolutePosition = getAbsolutePosition(TdElement1);
		if (x <= absolutePosition[0] + TdElement1.offsetWidth && y <= absolutePosition[1] + TdElement1.offsetHeight) {
			return "move";
		} else {
			return null;
		}
	}
}, doResize:function (event) {
	function subwindowAbsolutePosition(ax, ay, bx, by, cx, cy) {
		bx -= ax;
		by -= ay;
		cx -= ax;
		cy -= ay;
		var dx, dy;
		if (cx / bx < cy / by) {
			dx = cx;
			dy = parseInt(dx * by / bx);
		} else {
			dy = cy;
			dx = parseInt(dy * bx / by);
		}
		dx += ax;
		dy += ay;
		return [dx, dy];
	}
	var x, y;
	if (browserType == browserType1) {
		x = event.clientX + document.body.scrollLeft;
		y = event.clientY + document.body.scrollTop;
	} else {
		x = event.pageX;
		y = event.pageY;
	}
	var offsetParent = this.SubWindowElement.offsetParent;
	var left = 0;
	var top = 0;
	var right = left + document.body.clientWidth;
	var bottom = top + document.body.clientHeight;
	if (x < left) {
		x = left;
	} else {
		if (x > right) {
			x = right;
		}
	}
	if (y < top) {
		y = top;
	} else {
		if (y > bottom) {
			y = bottom;
		}
	}
	absolutePosition = getAbsolutePosition(this.SubWindowElement);
	left = absolutePosition[0];
	top = absolutePosition[1];
	right = left + this.SubWindowElement.offsetWidth;
	bottom = top + this.SubWindowElement.offsetHeight;
	var cursor = this.getCursor();
	switch (this.SubWindowElement.resizeModeSubwindow) {
	  case "e-resize":
		var right = cursor.offsetLeft + cursor.offsetWidth;
		if (right - x > 5) {
			cursor.style.left = x;
			if (browserType == browserType1) {
				cursor.style.width = right - x;
			} else {
				cursor.style.width = right - x - (cursor.offsetWidth - cursor.clientWidth);
			}
		}
		break;
	  case "w-resize":
		if (x - cursor.offsetLeft > 5) {
			cursor.style.width = x - cursor.offsetLeft;
		}
		break;
	  case "n-resize":
		var bottom = cursor.offsetTop + cursor.offsetHeight;
		if (bottom - y > 18) {
			cursor.style.top = y;
			if (browserType == browserType1) {
				cursor.style.height = bottom - y;
			} else {
				cursor.style.height = bottom - y - (cursor.offsetHeight - cursor.clientHeight);
			}
		}
		break;
	  case "s-resize":
		if (y - cursor.offsetTop > 18) {
			cursor.style.height = y - cursor.offsetTop;
		}
		break;
	  case "ne-resize":
		var absolutePosition;
		if (event.shiftKey || event.ctrlKey) {
			absolutePosition = subwindowAbsolutePosition(left, top, right, bottom, x, y);
		} else {
			absolutePosition = [x, y];
		}
		var width = right - absolutePosition[0];
		var height = bottom - absolutePosition[1];
		if (width > 5 && height > 18) {
			cursor.style.left = absolutePosition[0];
			cursor.style.top = absolutePosition[1];
			cursor.style.width = width;
			cursor.style.height = height;
		}
		break;
	  case "nw-resize":
		var absolutePosition;
		if (event.shiftKey || event.ctrlKey) {
			absolutePosition = subwindowAbsolutePosition(left, bottom, right, top, x, y);
		} else {
			absolutePosition = [x, y];
		}
		var width = absolutePosition[0] - left;
		var height = bottom - absolutePosition[1];
		if (width > 5 && height > 18) {
			cursor.style.top = absolutePosition[1];
			cursor.style.width = width;
			cursor.style.height = height;
		}
		break;
	  case "se-resize":
		var absolutePosition;
		if (event.shiftKey || event.ctrlKey) {
			absolutePosition = subwindowAbsolutePosition(right, top, left, bottom, x, y);
		} else {
			absolutePosition = [x, y];
		}
		var width = right - absolutePosition[0];
		var height = absolutePosition[1] - top;
		if (width > 5 && height > 18) {
			cursor.style.left = absolutePosition[0];
			cursor.style.width = width;
			cursor.style.height = height;
		}
		break;
	  case "sw-resize":
		var absolutePosition;
		if (event.shiftKey || event.ctrlKey) {
			absolutePosition = subwindowAbsolutePosition(left, top, right, bottom, x, y);
		} else {
			absolutePosition = [x, y];
		}
		var width = absolutePosition[0] - left;
		var height = absolutePosition[1] - top;
		if (width > 5 && height > 18) {
			cursor.style.width = width;
			cursor.style.height = height;
		}
		break;
	  case "move":
		var absolutePosition = getAbsolutePosition(this.SubWindowElement);
		cursor.style.left = absolutePosition[0] + (x - this.SubWindowElement.positionX);
		cursor.style.top = absolutePosition[1] + (y - this.SubWindowElement.positionY);
		break;
	}
}, getStatus:function () {
	return this.SubWindowElement.Status;
}, setStatus:function (status) {
	if (this.SubWindowElement.Status == status) {
		return;
	}
	if (!this.SubWindowElement.winFlag) {
		this.SubWindowElement.Status = status;
		return;
	}
	var subWindowStatus = this.SubWindowElement.Status;
	try {
		switch (subWindowStatus) {
		  case subWindowStatus00:
			this.SubWindowElement.subStylePositionWidth = this.SubWindowElement.style.position;
			this.SubWindowElement.subOffsetLeftPosition = this.SubWindowElement.offsetLeft;
			this.SubWindowElement.subOffsetTopPosition = this.SubWindowElement.offsetTop;
			if (this.SubWindowElement.$tB) {
				this.SubWindowElement.subWindowOffsetWidth = this.SubWindowElement.offsetWidth;
				this.SubWindowElement.subStylePositionHeight = this.SubWindowElement.offsetHeight;
			} else {
				this.SubWindowElement.subWindowOffsetWidth = this.SubWindowElement.style.width;
				this.SubWindowElement.subStylePositionHeight = this.SubWindowElement.style.height;
			}
			break;
		  case subWindowStatus02:
			var spacialSubwindow = this.SubWindowElement.subwindowTable;
			this.SubWindowElement.appendChild(spacialSubwindow);
			setComponentDisplay(this.subwindowDIV(), false);
			break;
		  case subWindowStatus03:
			if (this.SubWindowElement.uMap02 && this.SubWindowElement._beforeShow != null) {
				var fireArray = fireSaturnEvent(this.SubWindowElement, "beforeShow", [this.SubWindowElement]);
				if (fireArray != null) {
					throw fireArray;
				}
			}
			break;
		}
		subWindowTemp = this.SubWindowElement;
		var subwindowflag = false;
		var hasExpanded = false;
		switch (status) {
		  case subWindowStatus00:
			if (this.SubWindowElement.uMap02 && this.SubWindowElement._beforeRestore != null) {
				var fireArray = fireSaturnEvent(this.SubWindowElement, "beforeRestore", [this.SubWindowElement]);
				if (fireArray != null) {
					throw fireArray;
				}
			}
			if (this.SubWindowElement.styleCss) {
				setComponentDisplay(initSubWindow(), true);
			}
			if (parseInt(this.SubWindowElement.subWindowOffsetWidth) > 0) {
				this.SubWindowElement.style.left = this.SubWindowElement.subOffsetLeftPosition;
				this.SubWindowElement.style.top = this.SubWindowElement.subOffsetTopPosition;
				this.SubWindowElement.style.width = this.SubWindowElement.subWindowOffsetWidth;
				this.SubWindowElement.style.height = this.SubWindowElement.subStylePositionHeight;
				this.SubWindowElement.style.position = this.SubWindowElement.subStylePositionWidth;
			}
			this.SubWindowElement.style.zIndex = getzIndex();
			if (this.SubWindowElement.subwindowIMG) {
				this.SubWindowElement.subwindowIMG.src = __SKIN_PATH + "/subwindow_minimize.gif";
			}
			if (this.SubWindowElement.subwindowIMG1) {
				this.SubWindowElement.subwindowIMG1.src = __SKIN_PATH + "/subwindow_maximize.gif";
			}
			this.SubWindowElement.subwindowflag = true;
			this.SubWindowElement.hasExpanded = true;
			this.SubWindowElement.Status = status;
			if (this.SubWindowElement.uMap02) {
				fireSaturnEvent(this.SubWindowElement, "afterRestore", [this.SubWindowElement]);
			}
			break;
		  case subWindowStatus01:
			if (this.SubWindowElement.uMap02 && this.SubWindowElement._beforeMinimize != null) {
				var fireArray = fireSaturnEvent(this.SubWindowElement, "beforeMinimize", [this.SubWindowElement]);
				if (fireArray != null) {
					throw fireArray;
				}
			}
			setComponentDisplay(this.SubWindowElement.contentcontainer, false);
			if (typeof (this.SubWindowElement.subWindowOffsetWidth) == "number") {
				this.SubWindowElement.style.width = this.SubWindowElement.subWindowOffsetWidth;
			}
			this.SubWindowElement.style.height = 0;
			this.SubWindowElement.style.zIndex = getzIndex();
			if (this.SubWindowElement.subwindowIMG) {
				this.SubWindowElement.subwindowIMG.src = __SKIN_PATH + "/subwindow_normal.gif";
			}
			if (this.SubWindowElement.subwindowIMG1) {
				this.SubWindowElement.subwindowIMG1.src = __SKIN_PATH + "/subwindow_maximize.gif";
			}
			this.SubWindowElement.Status = status;
			if (this.SubWindowElement.uMap02) {
				fireSaturnEvent(this.SubWindowElement, "afterMinimize", [this.SubWindowElement]);
			}
			break;
		  case subWindowStatus02:
			if (this.SubWindowElement.uMap02 && this.SubWindowElement._beforeMaximize != null) {
				var fireArray = fireSaturnEvent(this.SubWindowElement, "beforeMaximize", [this.SubWindowElement]);
				if (fireArray != null) {
					throw fireArray;
				}
			}
			var spacialSubwindow = this.SubWindowElement.subwindowTable;
			var maximizeContainer = this.subwindowDIV();
			maximizeContainer.appendChild(spacialSubwindow);
			setComponentDisplay(maximizeContainer, true);
			if (this.SubWindowElement.subwindowIMG) {
				this.SubWindowElement.subwindowIMG.src = __SKIN_PATH + "/subwindow_minimize.gif";
			}
			if (this.SubWindowElement.subwindowIMG1) {
				this.SubWindowElement.subwindowIMG1.src = __SKIN_PATH + "/subwindow_normal.gif";
			}
			this.SubWindowElement.subwindowflag = true;
			this.SubWindowElement.hasExpanded = true;
			this.SubWindowElement.Status = status;
			if (this.SubWindowElement.uMap02) {
				fireSaturnEvent(this.SubWindowElement, "afterMaximize", [this.SubWindowElement]);
			}
			break;
		  case subWindowStatus03:
			if (this.SubWindowElement.uMap02 && this.SubWindowElement._beforeHide != null) {
				var fireArray = fireSaturnEvent(this.SubWindowElement, "beforeHide", [this.SubWindowElement]);
				if (fireArray != null) {
					throw fireArray;
				}
			}
			if (this.SubWindowElement.subwindowIMG) {
				this.SubWindowElement.subwindowIMG.src = __SKIN_PATH + "/subwindow_minimize.gif";
			}
			if (this.SubWindowElement.subwindowIMG1) {
				this.SubWindowElement.subwindowIMG1.src = __SKIN_PATH + "/subwindow_maximize.gif";
			}
			setComponentDisplay(this.SubWindowElement, false);
			if (this.SubWindowElement.styleCss) {
				setComponentDisplay(initSubWindow(), false);
			}
			this.SubWindowElement.Status = status;
			if (this.SubWindowElement.uMap02) {
				fireSaturnEvent(this.SubWindowElement, "afterHide", [this.SubWindowElement]);
			}
			this.SubWindowElement.subStylePositionWidth = this.SubWindowElement.style.position;
			this.SubWindowElement.subOffsetLeftPosition = 0;
			this.SubWindowElement.subOffsetTopPosition = 0;
			this.SubWindowElement.subWindowOffsetWidth = 0;
			this.SubWindowElement.subStylePositionHeight = 0;
			break;
		}
		switch (subWindowStatus) {
		  case subWindowStatus01:
			if (this.SubWindowElement.contentcontainer != null) {
				setComponentDisplay(this.SubWindowElement.contentcontainer, true);
			}
			if (!this.SubWindowElement.hasExpanded) {
				this.SubWindowElement._initChildren = null;
			}
			break;
		  case subWindowStatus03:
			setComponentDisplay(this.SubWindowElement, true);
			if (!this.SubWindowElement.hasExpanded) {
				this.SubWindowElement._initChildren = null;
			}
			if (this.SubWindowElement.uMap02) {
				fireSaturnEvent(this.SubWindowElement, "afterShow", [this.SubWindowElement]);
			}
			break;
		}
		if (hasExpanded) {
			this.SubWindowElement.hasExpanded = true;
		}
		if (subwindowflag) {
			excuteResize();
		}
		if (this.SubWindowElement.subwindowIMG) {
			setControlClassName(this.SubWindowElement.subwindowIMG, "WindowButton");
		}
		if (this.SubWindowElement.subwindowIMG1) {
			setControlClassName(this.SubWindowElement.subwindowIMG1, "WindowButton");
		}
		if (this.SubWindowElement.subButton) {
			setControlClassName(this.SubWindowElement.subButton, "WindowButton");
		}
	}
	catch (e) {
		outputExceptionMessage(e);
	}
}, onmouseoverSubWindow01:function (ButtonElement, event, subWin) {
	setControlClassName(ButtonElement, "HotWindowButton", subWin);
}, onmouseoutSubWindow01:function (ButtonElement, event) {
	setControlClassName(ButtonElement, "WindowButton", subWin);
}, onclickSubWindow01:function (SubWindowElement, ButtonElement, event, subWin) {
	if (SubWindowElement.Status == subWindowStatus01) {
		this.restore();
	} else {
		this.minimize();
	}
}, onclickSubWindow03:function (SubWindowElement, ButtonElement, event, subWin) {
	if (SubWindowElement.Status == subWindowStatus02) {
		this.restore();
	} else {
		this.maximize();
	}
}, onclickhidesubwindow:function (SubWindowElement, ButtonElement, event, subWin) {
	this.hide();
}, onmousemoveSubWindow:function (SubWindowElement, event, subWin) {
	if (SubWindowElement.resizeModeSubwindow) {
		subWin.doResize(event);
	}
}, onmousedownSubWindow:function (SubWindowElement, event, subWin) {
	var whichbutton;
	if (browserType == browserType1) {
		whichbutton = event.button;
	} else {
		whichbutton = event.which;
	}
	if (whichbutton != 1) {
		return;
	}
	SubWindowElement.resizeModeSubwindow = subWin.subWindowResizeProperties(event);
	if (SubWindowElement.resizeModeSubwindow != null) {
		if (browserType == browserType1) {
			var target = event.srcElement;
			target.unselectable = true;
		} else {
			setComponentDisplay(getDIVForSplitPanel(), true);
			var target = event.target;
			target.style.MozUserSelect = "none";
		}
		var cursor = this.getCursor();
		var absolutePosition = getAbsolutePosition(SubWindowElement);
		cursor.style.left = absolutePosition[0];
		cursor.style.top = absolutePosition[1];
		if (browserType == browserType1) {
			cursor.style.width = SubWindowElement.offsetWidth;
			cursor.style.height = SubWindowElement.offsetHeight;
		} else {
			cursor.style.width = SubWindowElement.clientWidth;
			cursor.style.height = SubWindowElement.clientHeight;
		}
		setComponentVisible(cursor, true);
		if (SubWindowElement.resizeModeSubwindow == "move") {
			SubWindowElement.subwindowTable.style.cursor = "move";
		}
		var x, y;
		if (browserType == browserType1) {
			SubWindowElement.setCapture(true);
			x = event.clientX + document.body.scrollLeft;
			y = event.clientY + document.body.scrollTop;
		} else {
			x = event.pageX;
			y = event.pageY;
			subWindowTemp = SubWindowElement;
			EventManager.addSystemEvent(window, "onmousemove", doDragSubWindows, true);
			EventManager.addSystemEvent(window, "onmouseup", setNewPositionSubWindows, true);
		}
		SubWindowElement.positionX = x;
		SubWindowElement.positionY = y;
	}
}, onmouseupSubWindow:function (SubWindowElement, event, subWin) {
	var whichbutton;
	if (browserType == browserType1) {
		whichbutton = event.button;
	} else {
		whichbutton = event.which;
	}
	if (whichbutton != 1) {
		return;
	}
	if (SubWindowElement.resizeModeSubwindow != null) {
		SubWindowElement.style.zIndex = getzIndex();
		var cursor = this.getCursor();
		var absolutePosition = getAbsolutePosition(cursor);
		var absolutePositionTemp = getAbsolutePosition(SubWindowElement);
		var width;
		var height;
		if (browserType == browserType1) {
			width = cursor.offsetWidth;
			height = cursor.offsetHeight;
		} else {
			width = cursor.clientWidth;
			height = cursor.clientHeight;
		}
		if (width > 5 || height > 5) {
			if (absolutePosition[0] != absolutePositionTemp[0] || absolutePosition[1] != absolutePositionTemp[1]) {
				try {
					var offsetLeftPosition = SubWindowElement.offsetLeft + (absolutePosition[0] - absolutePositionTemp[0]);
					var offsetTopPosition = SubWindowElement.offsetTop + (absolutePosition[1] - absolutePositionTemp[1]);
					if (this.SubWindowElement.uMap02 && this.SubWindowElement._beforeMove != null) {
						var fireArray = fireSaturnEvent(SubWindowElement, "beforeMove", [SubWindowElement, offsetLeftPosition, offsetTopPosition]);
						if (fireArray != null) {
							throw fireArray;
						}
					}
					SubWindowElement.style.position = "absolute";
					SubWindowElement.style.left = offsetLeftPosition;
					SubWindowElement.style.top = offsetTopPosition;
					this.setClassName(true);
					if (SubWindowElement.Status == subWindowStatus01) {
						SubWindowElement.subOffsetLeftPosition = SubWindowElement.offsetLeft;
						SubWindowElement.subOffsetTopPosition = SubWindowElement.offsetTop;
						if (browserType == browserType1) {
							SubWindowElement.subOffsetLeftPosition--;
							SubWindowElement.subOffsetTopPosition--;
						}
					}
					if (this.SubWindowElement.uMap02) {
						fireSaturnEvent(SubWindowElement, "afterMove", [this.SubWindowElement]);
					}
				}
				catch (e) {
					outputExceptionMessage(e);
				}
			}
			var offsetWidth1 = SubWindowElement.offsetWidth;
			var offsetWidth2 = SubWindowElement.offsetWidth;
			if (width != offsetWidth1 || height != offsetWidth2) {
				try {
					if (this.SubWindowElement.uMap02 && this.SubWindowElement._beforeResize != null) {
						var fireArray = fireSaturnEvent(this.SubWindowElement, "beforeResize", [this.SubWindowElement, width, height]);
						if (fireArray != null) {
							throw fireArray;
						}
					}
					SubWindowElement.style.tableLayout = "fixed";
					SubWindowElement.style.width = width;
					SubWindowElement.style.height = height;
					excuteResize();
					SubWindowElement.$tB = true;
					if (this.SubWindowElement.uMap02) {
						fireSaturnEvent(this.SubWindowElement, "afterResize", [this.SubWindowElement]);
					}
				}
				catch (e) {
					outputExceptionMessage(e);
				}
			}
		}
		setComponentVisible(cursor, false);
		if (browserType == browserType1) {
			SubWindowElement.releaseCapture();
		} else {
			setComponentDisplay(getDIVForSplitPanel(), false);
			EventManager.removeSystemEvent(window, "onmousemove", doDragSubWindows, true);
			EventManager.removeSystemEvent(window, "onmouseup", setNewPositionSubWindows, true);
			subWindowTemp = null;
		}
		SubWindowElement.resizeModeSubwindow = null;
		SubWindowElement.subwindowTable.style.cursor = "default";
	}
}, onclickSubWindow02:function (SubWindowElement, event, subWin) {
	switch (this.SubWindowElement.titleclickaction) {
	  case "maximize":
		if (this.getStatus() == subWindowStatus02) {
			this.setStatus(subWindowStatus00);
		} else {
			this.setStatus(subWindowStatus02);
		}
		break;
	  case "minimize":
		if (this.getStatus() == subWindowStatus01) {
			this.setStatus(subWindowStatus00);
		} else {
			this.setStatus(subWindowStatus01);
		}
		break;
	}
}, ondblclickSubWindow02:function (SubWindowElement, event, subWin) {
	switch (this.SubWindowElement.titledblclickaction) {
	  case "maximize":
		if (this.getStatus() == subWindowStatus02) {
			this.setStatus(subWindowStatus00);
		} else {
			this.setStatus(subWindowStatus02);
		}
		break;
	  case "minimize":
		if (this.getStatus() == subWindowStatus01) {
			this.setStatus(subWindowStatus00);
		} else {
			this.setStatus(subWindowStatus01);
		}
		break;
	}
}, setNewPositionSubWindows:function (event) {
	onmouseupSubWindow(subWindowTemp, event);
}, doDragSubWindows:function (event) {
	onmousemoveSubWindow(subWindowTemp, event);
}, getCursor:function () {
	var cursor = subwindowCousor;
	if (cursor == null) {
		cursor = document.createElement("DIV");
		setComponentVisible(cursor, false);
		cursor.className = "SubWindowDraggingCursor";
		document.body.appendChild(cursor);
		subwindowCousor = cursor;
	}
	cursor.style.zIndex = getzIndex();
	return cursor;
}, minimize:function () {
	this.setStatus(subWindowStatus01);
}, maximize:function () {
	this.setStatus(subWindowStatus02);
}, restore:function () {
	this.setStatus(subWindowStatus00);
}, hide:function () {
	this.setStatus(subWindowStatus03);
}, show:function (subStyleCss, center) {
	var scrollLeft = document.body.scrollLeft;
	var scrollTop = document.body.scrollTop;
	var clientWidth = document.body.clientWidth;
	var clientHeight = document.body.clientHeight;
	this.SubWindowElement.styleCss = subStyleCss;
	this.setStatus(subWindowStatus00);
	if (center) {
		var offsetWidth = this.SubWindowElement.offsetWidth;
		var offsetHeight = this.SubWindowElement.offsetHeight;
		this.SubWindowElement.style.position = "absolute";
		this.SubWindowElement.setClassName(true);
		this.SubWindowElement.style.left = scrollLeft + (clientWidth - offsetWidth) / 2;
		this.SubWindowElement.style.top = scrollTop + (clientHeight - offsetHeight) / 2;
	}
}, subwindowDIV:function () {
	var DIVElement2 = this.SubWindowElement.subWindowDIV;
	if (DIVElement2 == null) {
		var DIVElement2 = document.createElement("DIV");
		setControlClassName(DIVElement2, "Float" + this.SubWindowElement.ElementClassName);
		DIVElement2.style.position = "absolute";
		document.body.appendChild(DIVElement2);
		DIVElement2.style.left = 0;
		DIVElement2.style.top = 0;
		DIVElement2.style.width = "100%";
		DIVElement2.style.height = "100%";
		this.SubWindowElement.subWindowDIV = DIVElement2;
	}
	DIVElement2.style.zIndex = getzIndex();
	return DIVElement2;
}});
function TabBase() {
   
	this.tabsetObject = null;
	this.Div = null;
	this.visible = true;
	this.Disabled = false;
	this.Padding = null;
	this.tag = null;
	this.hasExpanded = false;
}
TabBase.prototype.destroy = function () {
	if (this.AutoCreateDiv && this.Div != null) {
		this.Div.parentNode.removeChild(this.Div);
	}
	this.tabsetObject = null;
	this.Div = null;
};
TabBase.prototype.getName = function () {
  
	return this.name01;
};
TabBase.prototype.getLabel = function () {
	return this.Label;
};
TabBase.prototype.setLabel = function (label) {
	this.Label = label;
	if (this.tabsetObject != null && this.tabsetObject.uMap02) {
		this.tabsetObject.refresh();
	}
};
TabBase.prototype.isVisible = function () {
	return this.visible;
};
TabBase.prototype.setVisible = function (visible) {
	this.visible = visible;
	if (this.tabsetObject != null && this.tabsetObject.uMap02) {
		this.tabsetObject.refresh();
	}
};
TabBase.prototype.isDisabled = function () {
	return this.visible;
};
TabBase.prototype.setDisabled = function (disabled) {
	this.Disabled = disabled;
	if (this.tabsetObject != null && this.tabsetObject.uMap02) {
		this.tabsetObject.refresh();
	}
};
TabBase.prototype.getPadding = function () {
	return this.Padding;
};
TabBase.prototype.setPadding = function (padding) {
	this.Padding = padding;
	if (this.tabsetObject != null && this.tabsetObject.uMap02) {
		this.Div.style.padding = padding;
	}
};
TabBase.prototype.getDiv = function () {
	return this.Div;
};
TabBase.prototype.getTag = getTag;
TabBase.prototype.setTag = setTag;
function Tab(name, label) {

  
  
	this.name01 = name;
	if (label) {
		this.Label = label;
	} else {
		this.Label = name;
	}
	this.AutoCreateDiv = false;
	this.AutoScroll = true;
}
Tab.prototype = new TabBase();
Tab.prototype.isAutoScroll = function () {
	return this.AutoScroll;
};
Tab.prototype.setAutoScroll = function (autoScroll) {
	this.AutoScroll = autoScroll;
};
Tab.prototype.isAutoCreateDiv = function () {
	return this.AutoCreateDiv;
};
Tab.prototype.setAutoCreateDiv = function (autoCreateDiv) {
	this.AutoCreateDiv = autoCreateDiv;
};
/**
* @description	setDIVProperties	è®¾ç½®å®¹å¨DIVå±æ§
*/
Tab.prototype.setDIVProperties = function () {
	if (this.viewFlag) {
		return;
	}
	var TabSetElement = this.tabsetObject;
	if (this.AutoCreateDiv) {
		DIVElement = document.createElement("DIV");
		var DIVElement3 = document.createElement("DIV");
		if (this.Padding) {
			DIVElement3.style.padding = this.Padding;
		}
		DIVElement3.style.width = "100%";
		DIVElement3.style.height = "100%";
		DIVElement.appendChild(DIVElement3);
		TabSetElement.contentcontainer.appendChild(DIVElement);
	} else {
	
	     
		DIVElement = document.getElementById(this.name01);
		
	}
	if (DIVElement != null) {
		if (!DIVElement.id) {
			DIVElement.id = "$2I" + addId();
		}
		setComponentDisplay(DIVElement, false);
		DIVElement.className = TabSetElement.ElementClassName + "$AM";
		DIVElement.style.width = "100%";
		DIVElement.style.height = "100%";
		if (this.AutoScroll) {
			DIVElement.style.overflow = "auto";
		} else {
			DIVElement.style.overflow = "hidden";
		}
		if (browserType == browserType1) {
			DIVElement.style.position = "absolute";
		} else {
			DIVElement.style.position = "relative";
		}
	}
	

	this.Div = DIVElement;
	this.viewFlag = true;
};
Tab.prototype.activate = function () {
	if (this.Div != null) {
		setComponentDisplay(this.Div, true);
		if (!this.hasExpanded) {
			//activateViewModel(this._initChildren);
			this._initChildren = null;
		}
		this.hasExpanded = true;
		excuteResize();
	}
};
Tab.prototype.deactivate = function () {
	if (this.Div != null) {
		setComponentDisplay(this.Div, false);
	}
};
Tab.prototype.getDiv = function () {
	if (this.Div != null) {
		return this.Div.firstChild;
	} else {
		return null;
	}
};
function FrameTab(name, label) {
	this.name01 = name;
	if (label) {
		this.Label = label;
	} else {
		this.Label = name;
	}
	this.Path = null;
	this.Cachable = true;
	this.frameFlag = false;
}
FrameTab.prototype = new TabBase();
FrameTab.prototype.getPath = function () {
	return this.Path;
};
FrameTab.prototype.setPath = function (path) {
	if (path.length > 0 && path.charAt(0) == "/") {
		path = __CONTEXT_PATH + path;
	}
	this.Path = path;
};
FrameTab.prototype.isCachable = function () {
	return this.Cachable;
};
FrameTab.prototype.setCachable = function (cachable) {
	this.Cachable = cachable;
};
FrameTab.prototype.setDIVProperties = function () {
	if (this.viewFlag) {
		return;
	}
	var TabSetElement = this.tabsetObject;
	var DIVElement = this.Div;
	var idAndName = TabSetElement.id + "_" + this.name01;
	var DIVElement = document.getElementById(idAndName);
	if (DIVElement == null) {
		DIVElement = document.createElement("DIV");
		DIVElement.innerHTML = "<IFRAME name=\"" + idAndName + "\" " + "frameborder=\"0\" style=\"width: 100%; height: 100%; padding: " + this.Padding + "\"></IFRAME>";
		TabSetElement.contentcontainer.appendChild(DIVElement);
	}
	if (!DIVElement.id) {
		DIVElement.id = "$2I" + addId();
	}
	DIVElement.className = TabSetElement.ElementClassName + "$AM";
	DIVElement.style.padding = 0;
	if (browserType == browserType1) {
		DIVElement.style.position = "absolute";
	} else {
		DIVElement.style.position = "relative";
		DIVElement.style.overflow = "hidden";
	}
	DIVElement.style.width = "100%";
	DIVElement.style.height = "100%";
	setComponentDisplay(DIVElement, false);
	this.Div = DIVElement;
	this.viewFlag = true;
};
FrameTab.prototype.activate = function () {
	if (this.Path != null) {
		if (!this.Cachable || !this.frameFlag) {
			var path = this.Path;
			var ContentContainerFirstChild1 = this.getFrame();
			ContentContainerFirstChild1.contentWindow.location.href = path;
			this.frameFlag = true;
		}
	}
	if (this.Div != null) {
		if (browserType == browserType1) {
			setComponentDisplay(this.Div, true);
			excuteResize();
		} else {
			if (navigator.userAgent.toLowerCase().indexOf("$tK")) {
				setComponentDisplay(this.Div, true);
				setTimeout("var DIVElement = document.getElementById(\"" + this.Div.id + "\");" + "setComponentDisplay(DIVElement, false);", 0);
				setTimeout("var DIVElement = document.getElementById(\"" + this.Div.id + "\");" + "setComponentDisplay(DIVElement, true);excuteResize();", 100);
			} else {
				setComponentDisplay(this.Div, true);
				setComponentDisplay(this.Div, false);
				setComponentDisplay(this.Div, true);
				excuteResize();
			}
		}
	}
};
FrameTab.prototype.deactivate = function () {
	if (!this.Cachable && this.frameFlag) {
		var ContentWindow = this.getFrame().contentWindow;
		ContentWindow.location.href = "about:blank";
	}
	if (this.Div != null) {
		setComponentDisplay(this.Div, false);
	}
};
FrameTab.prototype.getFrame = function () {
	return this.Div.firstChild;
};
saturnJspTag.TabSetComponent = Class.create();
saturnJspTag.TabSetComponent.prototype = Object.extend(new saturnJspTag.Base(), {initialize:function (id, tabPlacement) {
	this.TabSetElement = document.getElementById(id);
    if (!this.TabSetElement.className) {
		this.TabSetElement.className = "TabSet";
	}
	this.TabSetElement.ElementClassName = this.TabSetElement.className;
	this.TabSetElement = document.getElementById(id);
	this.TabSetElement.tabMap = new HashList();
	this.TabSetElement.CurrentTab = null;
	this.TabSetElement.ShowFrame = true;
	this.TabSetElement.TabPlacement = (tabPlacement) ? tabPlacement : "top";
}, destroy:function () {
	var tabMap1 = this.TabSetElement.tabMap;
	var tabMap1Size = tabMap1.size();
	for (var i = 0; i < tabMap1Size; i++) {
		var cArray02 = tabMap1.uArray3[i];
		cArray02.destroy();
	}
	this.TabSetElement.Tr1Element = null;
	this.TabSetElement.DIV1Element = null;
	this.TabSetElement.contentcontainer = null;
	this.TabSetElement.Table1Element = null;
	this.TabSetElement.BlankContainer = null;
}, activate:function (tabset) {
	if (!this.TabSetElement.uMap02) {
	  
		this.init(tabset);
		this.TabSetElement.uMap02 = true;
		if (!this.TabSetElement.ShowFrame) {
			this.setShowFrame(false);
		}
		this.refresh();
	}
}, outputTab:function (cArray02) {
	var tabMap1 = this.TabSetElement.tabMap;
	
	
	var firsttab =tabMap1.get(0);
	var tabname2=firsttab.name01;
		tabid=document.getElementById(tabname2);
	 
	var spacialObj = -1;
	if (cArray02 != null) {
		spacialObj = tabMap1.indexOf(cArray02.name01);
	}
	var size = tabMap1.size();
	
	
	
	for (var i = spacialObj + 1; i < size; i++) {

		var cArray02 = tabMap1.get(i);
		if (cArray02.visible && !cArray02.Disabled) {
			return cArray02;
		}
	}
	for (var i = spacialObj - 1; i >= 0; i--) {
		var cArray02 = tabMap1.get(i);
		if (cArray02.visible && !cArray02.Disabled) {
			return cArray02;
		}
	}
	return null;
}, refresh:function () {
	var TrElement2 = this.TabSetElement.Tr1Element;
	var rowsLength = TrElement2.childNodes.length;
	var TdElement2 = null;
	if (rowsLength > 0) {
		TdElement2 = TrElement2.childNodes[rowsLength - 1];
		TrElement2.removeChild(TdElement2);
		rowsLength--;
	}
	var TdElement, IMGElement4, label;
	var tabMap1 = this.TabSetElement.tabMap;
	var cArray03 = new Array();
	var size = tabMap1.size();
	for (var i = 0; i < size; i++) {
		var tabElement = tabMap1.get(i);
		if (!tabElement.viewFlag) {
			tabElement.setDIVProperties();
		}
		if (tabElement.visible) {
			cArray03.push(tabElement);
		}
	}
	var spacialObj = 0;
	for (var i = 0; i < cArray03.length; i++) {
		if (spacialObj < rowsLength) {
			TdElement = TrElement2.childNodes[spacialObj];
			IMGElement4 = TdElement.firstChild;
		} else {
			TdElement = document.createElement("TD");
			IMGElement4 = document.createElement("IMG");
			TdElement.appendChild(IMGElement4);
			TrElement2.appendChild(TdElement);
		}
		spacialObj++;
		if (i == 0) {
			IMGElement4.src = __SKIN_PATH + "/tab_1_first_" + this.TabSetElement.TabPlacement + ".gif";
		} else {
			IMGElement4.src = __SKIN_PATH + "/tab_1_" + this.TabSetElement.TabPlacement + ".gif";
		}
		var cArray02 = cArray03[i];
		if (spacialObj < rowsLength) {
			TdElement = TrElement2.childNodes[spacialObj];
			label = TdElement.firstChild;
		} else {
			TdElement = document.createElement("TD");
			label = document.createElement("DIV");
			TdElement.appendChild(label);
			TrElement2.appendChild(TdElement);
		}
		spacialObj++;
		TdElement.currentTab2 = cArray02;
		
		TdElement.saturnClass = "Tab";
		var src = "url(" + __SKIN_PATH + "/tab_2_" + this.TabSetElement.TabPlacement + ".gif)";
		if (TdElement.style.backgroundImage != src) {
			TdElement.style.backgroundImage = src;
		}
		if (cArray02.Disabled) {
			label.className = "DisabledTab_" + this.TabSetElement.TabPlacement;
		} else {
			label.className = "Tab_" + this.TabSetElement.TabPlacement;
		}
		label.style.whiteSpace = "nowrap";
		label.innerText = cArray02.Label;
	}
	if (cArray03.length > 0) {
		if (spacialObj < rowsLength) {
			TdElement = TrElement2.childNodes[spacialObj];
			IMGElement4 = TdElement.firstChild;
		} else {
			TdElement = document.createElement("TD");
			IMGElement4 = document.createElement("IMG");
			TdElement.appendChild(IMGElement4);
			TrElement2.appendChild(TdElement);
		}
		spacialObj++;
		IMGElement4.src = __SKIN_PATH + "/tab_3_last_" + this.TabSetElement.TabPlacement + ".gif";
	}
	for (var i = rowsLength - 1; i >= spacialObj; i--) {
		TrElement2.deleteCell(i);
	}
	if (TdElement2 == null) {
		TdElement2 = document.createElement("TD");
		this.TabSetElement.BlankContainer = TdElement2;
		TdElement2.align = "right";
		TdElement2.style.width = "100%";
	}
	TrElement2.appendChild(TdElement2);
	var src;
	if (cArray03.length > 0) {
		src = "url(" + __SKIN_PATH + "/tab_blank_" + this.TabSetElement.TabPlacement + ".gif)";
	} else {
		if (this.TabSetElement.ShowFrame) {
			TrElement2.style.height = 2;
			src = "url(" + __SKIN_PATH + "/tab_blank_border_" + this.TabSetElement.TabPlacement + ".gif)";
		} else {
			TrElement2.style.height = 0;
			src = "url(none)";
		}
	}
	if (TdElement2.style.backgroundImage != src) {
		TdElement2.style.backgroundImage = src;
	}
	var currentTab1 = this.TabSetElement.CurrentTab;
	if (currentTab1 == null || currentTab1.Disabled) {
		currentTab1 = this.outputTab(currentTab1);
	}
	this.getTabCell(currentTab1);
}, init:function (tabset) {
	function initTab(TabSetElement, TrElement, tabset) {
	
	    
		var TdElement = TrElement.cells[0];
		TdElement.vAlign = "top";
		var DIVElement4 = document.createElement("DIV");
	
		
		
		DIVElement4.style.width = "100%";
		DIVElement4.style.height = "100%";
		DIVElement4.style.display = "";
		DIVElement4.style.scroll = "hidden";
		var TableElement2 = document.createElement("TABLE");
		TableElement2.style.width = "100%";
		TableElement2.style.height = "100%";
		TableElement2.cellPadding = 0;
		TableElement2.cellSpacing = 0;
		var TrElement2 = document.createElement("TR");
		var TbodyElement2 = document.createElement("TBODY");
		TbodyElement2.appendChild(TrElement2);
		TableElement2.appendChild(TbodyElement2);
		DIVElement4.appendChild(TableElement2);
		EventManager.addSystemEvent(TrElement2, "onclick", function (event) {
		
			tabset.onclickTabSet(TabSetElement, event);
		});
		TabSetElement.Tr1Element = TrElement2;
		TabSetElement.DIV1Element = DIVElement4;
		
	
		
		TdElement.appendChild(DIVElement4);
		if (browserType == browserType1) {
		EventManager.addSystemEvent(this.TabSetElement, "onresize", function (event) {
			this.onResize();
		});
	}
	}
	function setDefaultTab(TabSetElement, TrElement) {
		TrElement.style.height = "100%";
		TdElement = TrElement.cells[0];
		TdElement.height = "100%";
		TdElement.vAlign = "top";
		var DIVElement1 = TdElement.firstChild;
		DIVElement1.style.width = "100%";
		DIVElement1.style.height = "100%";
		DIVElement1.className = TabSetElement.ElementClassName + "ContentContainer_" + TabSetElement.TabPlacement;
		TabSetElement.contentcontainer = DIVElement1;
		
	}
	this.TabSetElement.cellPadding = 0;
	this.TabSetElement.cellSpacing = 0;
	var TbodyElement = this.TabSetElement.tBodies[0];
	if (this.TabSetElement.TabPlacement == "top") {
		var TrElement = TbodyElement.rows[0];
		initTab(this.TabSetElement, TrElement, tabset);
		TrElement = TbodyElement.rows[1];
		setDefaultTab(this.TabSetElement, TrElement);
	} else {
		TrElement = TbodyElement.rows[0];
		setDefaultTab(this.TabSetElement, TrElement, tabset);
		var TrElement = TbodyElement.rows[1];
		initTab(this.TabSetElement, TrElement, tabset);
	}
}, addTab:function (cArray02) {
   
	var name = cArray02.name01;
	this.TabSetElement.tabMap.put(name, cArray02);
	cArray02.tabsetObject = this.TabSetElement;
	if (this.TabSetElement.uMap02) {
		this.refresh();
	}
	return cArray02;
}, getTab:function (name) {
    
	return this.TabSetElement.tabMap.get(name);
}, removeTab:function (cArray02) {
	if (typeof (cArray02) == "string") {
		cArray02 = this.getTab(cArray02);
		if (cArray02 == null) {
			return null;
		}
	}
	if (this.TabSetElement.CurrentTab == cArray02) {
		this.getTabCell(this.TabSetElement.outputTab(cArray02));
	}
	this.TabSetElement.tabMap.remove(cArray02.name01);
	if (this.TabSetElement.uMap02) {
		this.refresh();
	}
	cArray02.destroy();
	return cArray02;
}, removeAllTabs:function () {
	var uMapTab = this.TabSetElement.uMap02;
	this.TabSetElement.uMap02 = false;
	var size1 = this.getTabCount();
	for (var i = size1 - 1; i >= 0; i--) {
		var cArray02 = this.getTab(i);
		this.removeTab(cArray02);
	}
	this.TabSetElement.uMap02 = uMapTab;
	if (this.TabSetElement.uMap02) {
		this.refresh();
	}
}, getTabCount:function () {
	return this.TabSetElement.tabMap.size();
}, getCurrentTab:function () {
	return this.TabSetElement.CurrentTab;
}, setCurrentTab:function (cArray02) {
	if (typeof (cArray02) != "object") {
	 
		cArray02 = this.TabSetElement.tabMap.get(cArray02);
		var tabname1=cArray02.name01;
		tabid=document.getElementById(tabname1);
	}
	if (this.TabSetElement.CurrentTab != cArray02) {
	
		this.getTabCell(cArray02);
	}
	return cArray02;
}, isShowFrame:function () {
	return this.TabSetElement.ShowFrame;
}, setShowFrame:function (showFrame) {
	this.TabSetElement.ShowFrame = showFrame;
	if (!this.TabSetElement.uMap02) {
		return;
	}
	var DIVElement2 = this.TabSetElement.contentcontainer;
	if (this.TabSetElement.TabPlacement == "top") {
		if (showFrame) {
			DIVElement2.style.borderBottomStyle = "";
			DIVElement2.style.borderLeftStyle = "";
			DIVElement2.style.borderRightStyle = "";
		} else {
			DIVElement2.style.borderBottomStyle = "none";
			DIVElement2.style.borderLeftStyle = "none";
			DIVElement2.style.borderRightStyle = "none";
		}
	} else {
		if (showFrame) {
			DIVElement2.style.borderTopStyle = "";
			DIVElement2.style.borderLeftStyle = "";
			DIVElement2.style.borderRightStyle = "";
		} else {
			DIVElement2.style.borderTopStyle = "none";
			DIVElement2.style.borderLeftStyle = "none";
			DIVElement2.style.borderRightStyle = "none";
		}
	}
}, getTabPlacement:function () {
	return this.TabSetElement.TabPlacement;
}, setTabPlacement:function (tabPlacement) {
	this.TabSetElement.TabPlacement = tabPlacement;
}, getContentContainer:function () {
	return this.TabSetElement.contentcontainer;
}, getBlankContainer:function () {
	return this.TabSetElement.BlankContainer;
}, getTabCell:function (cArray02) {

   
     
	function getTabCell(TrElement2, spacialObj) {
		return TrElement2.cells[spacialObj * 2 + 1];
	}
	if (this.TabSetElement.uMap02) {
		var tabSetFlag = (this.TabSetElement.$X7 || (this.TabSetElement.CurrentTab != cArray02));
		if (cArray02 != null && (cArray02.Disabled)) {
			return;
		}
		try {
			var tabMap1 = this.TabSetElement.tabMap;
			var cArray03 = new Array();
			var size = tabMap1.size();
			for (var i = 0; i < size; i++) {
				var tabElement = tabMap1.get(i);
				if (tabElement.visible) {
					cArray03.push(tabElement);
				}
			}
			var TrElement2 = this.TabSetElement.Tr1Element;
			var currentTab2 = this.TabSetElement.CurrentTab;
			if (tabSetFlag && this.TabSetElement._beforeTabChange != null) {
				var fireArray = fireSaturnEvent(this.TabSetElement, "beforeTabChange", [this.TabSetElement, cArray02]);
				if (fireArray != null) {
					throw fireArray;
				}
			}
			if (currentTab2 != null) {
				var spacialObj = cArray03.indexOf(currentTab2);
				if (spacialObj >= 0) {
					var tabIndex = spacialObj * 2 + 1;
					var tabCellObj = TrElement2.cells[tabIndex - 1];
					if (spacialObj == 0) {
						tabCellObj.firstChild.src = __SKIN_PATH + "/tab_1_first_" + this.TabSetElement.TabPlacement + ".gif";
					} else {
						tabCellObj.firstChild.src = __SKIN_PATH + "/tab_1_" + this.TabSetElement.TabPlacement + ".gif";
					}
					var tabCellSiblingObj = TrElement2.cells[tabIndex];
					tabCellSiblingObj.style.backgroundImage = "url(" + __SKIN_PATH + "/tab_2_" + this.TabSetElement.TabPlacement + ".gif)";
					var label = tabCellSiblingObj.firstChild;
					if (currentTab2.Disabled) {
						label.className = "DisabledTab_" + this.TabSetElement.TabPlacement;
					} else {
						label.className = "Tab_" + this.TabSetElement.TabPlacement;
					}
					var tabCellSibling1Obj = TrElement2.cells[tabIndex + 1];
					if (spacialObj == cArray03.length - 1) {
						tabCellSibling1Obj.firstChild.src = __SKIN_PATH + "/tab_3_last_" + this.TabSetElement.TabPlacement + ".gif";
					} else {
						tabCellSibling1Obj.firstChild.src = __SKIN_PATH + "/tab_1_" + this.TabSetElement.TabPlacement + ".gif";
					}
				}
				if (tabSetFlag) {
					currentTab2.deactivate();
				}
			}
			currentTab2 = cArray02;
			if (cArray02 != null) {
				var spacialObj = cArray03.indexOf(cArray02);
				if (spacialObj >= 0) {
					var tabIndex = spacialObj * 2 + 1;
					var tabCellObj = TrElement2.cells[tabIndex - 1];
					if (spacialObj == 0) {
						tabCellObj.firstChild.src = __SKIN_PATH + "/tab_1_current_first_" + this.TabSetElement.TabPlacement + ".gif";
					} else {
						tabCellObj.firstChild.src = __SKIN_PATH + "/tab_1_current_" + this.TabSetElement.TabPlacement + ".gif";
					}
					var tabCellSiblingObj = TrElement2.cells[tabIndex];
					var label = tabCellSiblingObj.firstChild;
					label.className = "CurrentTab_" + this.TabSetElement.TabPlacement;
					tabCellSiblingObj.style.backgroundImage = "url(" + __SKIN_PATH + "/tab_2_current_" + this.TabSetElement.TabPlacement + ".gif)";
					var tabCellSibling1Obj = TrElement2.cells[tabIndex + 1];
					if (spacialObj == cArray03.length - 1) {
						tabCellSibling1Obj.firstChild.src = __SKIN_PATH + "/tab_3_current_last_" + this.TabSetElement.TabPlacement + ".gif";
					} else {
						tabCellSibling1Obj.firstChild.src = __SKIN_PATH + "/tab_3_current_" + this.TabSetElement.TabPlacement + ".gif";
					}
				}
				if (tabSetFlag) {
					cArray02.activate();
				}
			}
			if (tabSetFlag) {
				this.TabSetElement.CurrentTab = cArray02;
				this.TabSetElement.$X7 = false;
				fireSaturnEvent(this.TabSetElement, "afterTabChange", [this.TabSetElement, cArray02]);
			}
		}
		catch (e) {
			outputExceptionMessage(e);
		}
	} else {
		this.TabSetElement.CurrentTab = cArray02;
		this.TabSetElement.$X7 = true;
	}
}, onclickTabSet:function (TabSetElement, event) {

    
   
	var whichTabElement;
	if (browserType == browserType1) {
	
		whichTabElement = event.srcElement;
	
	} else {
	
		whichTabElement = event.target;
	}
	whichTabElement = getParentNode(whichTabElement, "Tab");
	
	if (whichTabElement != null) {
	    
		var cArray02 = whichTabElement.currentTab2;
	    var tabname=cArray02.name01;
	 
		tabid=document.getElementById(tabname);
		
		this.getTabCell(cArray02);
	}
}, onResize:function () {
	if (!this.TabSetElement.uMap02) {
		return;
	}
	if (this.TabSetElement.Timeout2) {
		clearTimeout(this.TabSetElement.Timeout2);
	}
	this.TabSetElement.Timeout2 = setTimeout("var TabSetElement = document.getElementById(\"" + this.TabSetElement.id + "\");" + "if (TabSetElement != null) TabSetElement.setTabSetScrollBarDisplay()", 150);
}, setTabSetScrollBarDisplay:function () {
	var DIVElement4 = this.TabSetElement.DIV1Element;
	if (DIVElement4.scrollWidth > DIVElement4.offsetWidth) {
		var tabsetscrollBar = this.setTabSetScrollBar();
		setComponentDisplay(tabsetscrollBar, true);
		this.setTabSetOffset();
	} else {
		var tabsetscrollBar = this.TabSetElement.Table1Element;
		if (tabsetscrollBar != null) {
			setComponentDisplay(tabsetscrollBar, false);
		}
	}
}, setTabSetOffset:function () {
	var DIVElement4 = this.TabSetElement.DIV1Element;
	var tabsetscrollBar = this.setTabSetScrollBar();
	tabsetscrollBar.style.left = DIVElement4.scrollLeft + DIVElement4.offsetWidth - tabsetscrollBar.offsetWidth - 4;
	tabsetscrollBar.style.top = 4;
}, setTabSetScrollBar:function () {
	var TableElement3 = this.TabSetElement.Table1Element;
	if (TableElement3 == null) {
		var TbodyElement = document.createElement("TBODY");
		var TrElement = document.createElement("TR");
		var TabSetElement = this.TabSetElement;
		var TdElement, ButtonElement;
		TdElement = document.createElement("TD");
		ButtonElement = document.createElement("IMG");
		ButtonElement.src = __SKIN_PATH + "/tabset_scroll1.gif";
		ButtonElement.Type1 = "$zD";
		TdElement.appendChild(ButtonElement);
		TrElement.appendChild(TdElement);
		EventManager.addSystemEvent(ButtonElement, "onclick", function (event) {
			onclickTabSetScrollBar(TabSetElement, event);
		});
		TdElement = document.createElement("TD");
		ButtonElement = document.createElement("IMG");
		ButtonElement.src = __SKIN_PATH + "/tabset_scroll2.gif";
		ButtonElement.Type1 = "$03";
		TdElement.appendChild(ButtonElement);
		TrElement.appendChild(TdElement);
		EventManager.addSystemEvent(ButtonElement, "onclick", function (event) {
			onclickTabSetScrollBar(TabSetElement, event);
		});
		TbodyElement.appendChild(TrElement);
		TableElement3 = document.createElement("TABLE");
		TableElement3.appendChild(TbodyElement);
		TableElement3.cellPadding = 0;
		TableElement3.cellSpacing = 0;
		TableElement3.style.position = "absolute";
		this.TabSetElement.DIV1Element.appendChild(TableElement3);
		this.TabSetElement.Table1Element = TableElement3;
	}
	return TableElement3;
}, onclickTabSetScrollBar:function (TabSetElement, event) {
	var target;
	if (browserType == browserType1) {
		target = event.srcElement;
	} else {
		target = event.target;
	}
	var DIVElement4 = TabSetElement.DIV1Element;
	if (target.Type1 == "$zD") {
		DIVElement4.scrollLeft -= 40;
	} else {
		if (target.Type1 == "$03") {
			DIVElement4.scrollLeft += 40;
		}
	}
	TabSetElement.setTabSetOffset();
}});
saturnJspTag.GroupBoxComponent = Class.create();
saturnJspTag.GroupBoxComponent.prototype = Object.extend(new saturnJspTag.Base(), {initialize:function (id) {
	this.GroupBoxElement = document.getElementById(id);
	this.GroupBoxElement.style.overflow = "visible";
	if (!this.GroupBoxElement.className) {
		this.GroupBoxElement.className = "GroupBox";
	}
	this.GroupBoxElement.ElementClassName = this.GroupBoxElement.className;
	this.GroupBoxElement.Title = "";
	this.GroupBoxElement.ShowExpandButton = true;
	this.GroupBoxElement.Expanded = true;
	this.GroupBoxElement.hasExpanded = false;
}, destroy:function () {
	this.GroupBoxElement.TitleContainer = null;
	this.GroupBoxElement.IMG2Element = null;
	this.GroupBoxElement.contentcontainer = null;
}, activate:function (autoform) {
	if (!this.GroupBoxElement.uMap02) {
		this.rebuild(autoform);
		if (!this.GroupBoxElement.Expanded) {
			this.GroupBoxElement.Expanded = true;
			this.setExpanded(false);
		} else {
			if (this.GroupBoxElement.IMG2Element != null) {
				this.GroupBoxElement.IMG2Element.src = __SKIN_PATH + "/groupbox_collapse.gif";
			}
			if (typeof (this.GroupBoxElement._initChildren) == "function") {
				this.GroupBoxElement._initChildren();
				this.GroupBoxElement._initChildren = null;
			}
		}
		this.GroupBoxElement.TitleContainer.innerHTML = this.GroupBoxElement.Title;
		this.GroupBoxElement.uMap02 = true;
		fireSaturnEvent(this.GroupBoxElement, "onActive", [this.GroupBoxElement]);
	}
}, rebuild:function (autoform) {
	var LEGENDElement, DIVElement1;
	for (var i = this.GroupBoxElement.childNodes.length - 1; i >= 0; i--) {
		var NodesLastRecord = this.GroupBoxElement.childNodes[i];
		if (NodesLastRecord.tagName.toUpperCase() == "LEGEND") {
			LEGENDElement = NodesLastRecord;
		} else {
			if (NodesLastRecord.tagName.toUpperCase() == "DIV") {
				DIVElement1 = NodesLastRecord;
			}
		}
	}
	LEGENDElement.className = this.GroupBoxElement.ElementClassName + "Title";
	DIVElement1.className = this.GroupBoxElement.ElementClassName + "ContentContainer";
	var TdElement, TrElement, TbodyElement;
	var TdElement8, IMGElement3;
	TbodyElement = document.createElement("TBODY");
	TdElement = document.createElement("TD");
	TdElement8 = TdElement;
	TrElement = document.createElement("TR");
	TrElement.appendChild(TdElement);
	TbodyElement.appendChild(TrElement);
	if (this.GroupBoxElement.ShowExpandButton) {
		TdElement = document.createElement("TD");
		IMGElement3 = document.createElement("IMG");
		IMGElement3.className = this.GroupBoxElement.ElementClassName + "ExpandButton";
		TdElement.appendChild(IMGElement3);
		TrElement.appendChild(TdElement);
	}
	TbodyElement.appendChild(TrElement);
	var TableElement = document.createElement("TABLE");
	TableElement.appendChild(TbodyElement);
	LEGENDElement.appendChild(TableElement);
	DIVElement1.style.width = "100%";
	DIVElement1.style.height = "100%";
	if (IMGElement3 != null) {
		var GroupBoxElement = this.GroupBoxElement;
		EventManager.addSystemEvent(IMGElement3, "onclick", function (event) {
			autoform.onclickGroupBox(GroupBoxElement, event, autoform);
		});
	}
	this.GroupBoxElement.TitleContainer = TdElement8;
	this.GroupBoxElement.IMG2Element = IMGElement3;
	this.GroupBoxElement.contentcontainer = DIVElement1;
	this.GroupBoxElement.winFlag = true;
}, getTitle:function () {
	return this.GroupBoxElement.Title;
}, setTitle:function (title) {
	if (this.GroupBoxElement.uMap02) {
		this.GroupBoxElement.TitleContainer.innerHTML = title;
	}
	this.GroupBoxElement.Title = title;
}, isShowExpandButton:function () {
	return this.GroupBoxElement.ShowExpandButton;
}, setShowExpandButton:function (showExpandButton) {
	this.GroupBoxElement.ShowExpandButton = showExpandButton;
}, isExpanded:function () {
	return this.GroupBoxElement.Expanded;
}, setExpanded:function (expanded) {
	if (this.GroupBoxElement.Expanded == expanded) {
		return;
	}
	if (!this.GroupBoxElement.winFlag) {
		this.GroupBoxElement.Expanded = expanded;
		return;
	}
	if (expanded) {
		this.GroupBoxElement.style.height = this.GroupBoxElement.offsetHeight2;
	} else {
		this.GroupBoxElement.offsetHeight2 = this.GroupBoxElement.offsetHeight - this.GroupBoxElement.TitleContainer.offsetHeight;
		this.GroupBoxElement.style.height = 1;
	}
	setComponentDisplay(this.GroupBoxElement.contentcontainer, expanded);
	this.GroupBoxElement.Expanded = expanded;
	if (this.GroupBoxElement.IMG2Element != null) {
		if (expanded) {
			this.GroupBoxElement.IMG2Element.src = __SKIN_PATH + "/groupbox_collapse.gif";
		} else {
			this.GroupBoxElement.IMG2Element.src = __SKIN_PATH + "/groupbox_expand.gif";
		}
	}
	if (expanded) {
		if (!this.GroupBoxElement.hasExpanded) {
			this.GroupBoxElement._initChildren = null;
		}
		this.GroupBoxElement.hasExpanded = true;
		excuteResize();
	}
}, expand:function () {
	this.setExpanded(true);
}, collapse:function () {
	this.setExpanded(false);
}, getContentContainer:function () {
	return this.GroupBoxElement.contentcontainer;
}, onclickGroupBox:function (GroupBoxElement, event, autoform) {
	autoform.setExpanded(!GroupBoxElement.Expanded);
}});
var cArray13 = new Array();
var DIVElement17 = null;
var TrElement12 = null;
var TrElement13 = null;
/**
* @description	initMenuItem		初始化MenuItem				
*/
function initMenuItem() {
	if (DIVElement17 == null) {
		var TrElement, TdElement;
		TrElement = document.createElement("TR");
		TdElement = document.createElement("TD");
		TdElement.style.width = "18";
		TrElement.appendChild(TdElement);
		TdElement = document.createElement("TD");
		TdElement.style.width = "4";
		TrElement.appendChild(TdElement);
		TdElement = document.createElement("TD");
		TdElement.style.whiteSpace = "nowrap";
		TrElement.appendChild(TdElement);
		TdElement = document.createElement("TD");
		TdElement.style.width = "16";
		TrElement.appendChild(TdElement);
		var TbodyElement = document.createElement("TBODY");
		TbodyElement.appendChild(TrElement);
		var TableElement = document.createElement("TABLE");
		TableElement.style.width = "100%";
		TableElement.style.height = "100%";
		TableElement.cellPadding = 0;
		TableElement.cellSpacing = 0;
		TableElement.appendChild(TbodyElement);
		var DIVElement = document.createElement("DIV");
		DIVElement.className = "MenuItem";
		DIVElement.appendChild(TableElement);
		DIVElement17 = DIVElement;
	}
	return DIVElement17;
}
/**
* @description	initOutlookBarSubButton		初始化OutlookBarSubButton			
*/
function initOutlookBarSubButton() {
	/**
* @description	setItemInitialMode		初始化Item				
*/
	function setItemInitialMode(ButtonElement) {
		var elementWrited = "<TABLE cellPadding=\"0\" cellSpacing=\"0\" style=\"height: 100%; TableElement-layout: fixed\">" + "<TR><TD align=\"center\" style=\"width: 100%\"><IMG class=\"SubIcon\"></TD>" + "<TD rowSpan=\"2\" style=\"width: 4\"></TD></TR>" + "<TR><TD align=\"center\"><DIV class=\"SubLabel\"></TD></TR></TABLE>";
		ButtonElement.innerHTML = elementWrited;
	}
	if (TrElement12 == null) {
		var ButtonElement = document.createElement("DIV");
		ButtonElement.saturnClass = "OutlookBarSubButton";
		setItemInitialMode(ButtonElement);
		var TdElement = document.createElement("TD");
		TdElement.align = "center";
		TdElement.appendChild(ButtonElement);
		var TrElement = document.createElement("TR");
		TrElement.appendChild(TdElement);
		TrElement12 = TrElement;
	}
	return TrElement12;
}
/**
* @description	initOutlookBarSubButton1		初始化OutlookBarSubButton1			
*/
function initOutlookBarSubButton1() {
	function setItemInitialMode(ButtonElement) {
		var elementWrited = "<TABLE cellPadding=\"0\" cellSpacing=\"0\" style=\"width: 100%; height: 100%\">" + "<TR><TD align=\"center\" style=\"width: 1\"><IMG class=\"SubIcon\"></TD>" + "<TD><DIV class=\"SubLabel\"></TD><TD style=\"width: 8\"></TD></TR></TABLE>";
		ButtonElement.innerHTML = elementWrited;
	}
	if (TrElement13 == null) {
		var ButtonElement = document.createElement("DIV");
		ButtonElement.saturnClass = "OutlookBarSubButton";
		setItemInitialMode(ButtonElement);
		var TdElement = document.createElement("TD");
		TdElement.align = "center";
		TdElement.appendChild(ButtonElement);
		var TrElement = document.createElement("TR");
		TrElement.appendChild(TdElement);
		TrElement13 = TrElement;
	}
	return TrElement13;
}
function MenuItem(name, label) {
	this.name01 = name;
	this.Label = (label) ? label : name;
	this.Icon = null;
	this.DisableIcon = null;
	this.Disabled = false;
	this.visible = true;
	this.Path = null;
	this.tag = null;
}
MenuItem.prototype.destroy = function () {
	if (this.GroupBoxElement2 != null) {
		if (this.GroupBoxElement2.Opened) {
			this.GroupBoxElement2.hide();
		}
		this.GroupBoxElement2 = null;
	}
	var items = this.getItems();
	var size = items.size();
	for (var i = 0; i < size; i++) {
		var item = items.get(i);
		item.destroy();
	}
};
MenuItem.prototype.getName = function () {
	return this.name01;
};
MenuItem.prototype.getLabel = function () {
	return this.label;
};
MenuItem.prototype.setLabel = function (label) {
	this.label = label;
};
MenuItem.prototype.getIcon = function () {
	return this.Icon;
};
MenuItem.prototype.setIcon = function (IMGElement7) {
	this.Icon = IMGElement7;
};
MenuItem.prototype.getDisableIcon = function () {
	return this.DisableIcon;
};
MenuItem.prototype.setDisableIcon = function (disableIcon) {
	this.DisableIcon = disableIcon;
};
MenuItem.prototype.isDisabled = function () {
	return this.Disabled;
};
MenuItem.prototype.setDisabled = function (disabled) {
	this.Disabled = disabled;
};
MenuItem.prototype.isVisible = function () {
	return this.visible;
};
MenuItem.prototype.setVisible = function (visible) {
	this.visible = visible;
};
MenuItem.prototype.getPath = function () {
	return this.Path;
};
MenuItem.prototype.setPath = function (path) {
	if (path.length > 0 && path.charAt(0) == "/") {
		path = __CONTEXT_PATH + path;
	}
	this.Path = path;
};
MenuItem.prototype.getTag = getTag;
MenuItem.prototype.setTag = setTag;
MenuItem.prototype.getItems = function () {
	if (this.Items == null) {
		this.Items = new HashList();
	}
	return this.Items;
};
MenuItem.prototype.addItem = function (item) {
	var items = this.getItems();
	items.put(item.name01, item);
	item.iterateMenuItem(this.menu);
};
MenuItem.prototype.removeItem = function (item) {
	this.getItems().remove(item);
	item._parent = null;
	item.iterateMenuItem(null);
};
MenuItem.prototype.getItem = function (name) {
	return this.Items.get(name);
};
MenuItem.prototype.remove = function () {
	this._parent.removeItem(this);
};
MenuItem.prototype.click = function () {
	var Menu = this.menu;
	var path = this.Path;
	if (path != null) {
		if (Menu.Target != null) {
			open(path, Menu.Target);
		} else {
			open(path, "_self");
		}
	}
};
MenuItem.prototype.iterateMenuItem = function (Menu) {
	this.menu = Menu;
	var items = this.getItems();
	var size = items.size();
	for (var i = 0; i < size; i++) {
		var item = items.get(i);
		item.iterateMenuItem(Menu);
	}
};
/**
* @description	Menu	声明组件Menu
* @param		id	
*/
function Menu(id) {
	if (!id) {
		id = controlId();
	}
	this.id = id;
	var menuItem = new MenuItem();
	menuItem.iterateMenuItem(this);
	this.TopItem = menuItem;
	this.GroupBoxElement3 = null;
	this.PopupContainer = null;
	cArray13.push(this);
	this.getXMLRootNode();
}
Menu.prototype.destroy = function () {
	this.detroyGroupBoxElement();
	this.TopItem.destroy();
	this.TopItem.iterateMenuItem(null);
};
Menu.prototype.getTopItem = function () {
	return this.TopItem;
};
Menu.prototype.getXMLRootNode = function () {
	if (this.hasXMLData) {
		return;
	}
	this.hasXMLData = true;
	var xmlNode = document.getElementById(this.id);
	if (xmlNode != null) {
		var firstLevelNodes;
		if (browserType == browserType1) {
			firstLevelNodes = xmlNode.documentElement;
		} else {
			firstLevelNodes = xmlNode.getElementsByTagName("items")[0];
		}
		if (firstLevelNodes != null) {
			this.iterateXMLNodes(this.TopItem, firstLevelNodes, 1);
		}
	}
};
Menu.prototype.iterateXMLNodes = function (item, rootNode) {
	var childNodesArray = rootNode.childNodes;
	for (var i = 0; i < childNodesArray.length; i++) {
		var childNode3 = childNodesArray[i];
		if (browserType == browserType1 || childNode3.nodeName.charAt(0) != "#") {
			var menuItem1 = new MenuItem(childNode3.getAttribute("name"));
			menuItem1.Label = childNode3.getAttribute("label");
			menuItem1.Path = childNode3.getAttribute("path");
			menuItem1.Icon = childNode3.getAttribute("icon");
			menuItem1.DisableIcon = childNode3.getAttribute("disableIcon");
			menuItem1.Disabled = parseBoolean(childNode3.getAttribute("disabled"));
			var visible = childNode3.getAttribute("visible");
			if (visible != null) {
				menuItem1.visible = parseBoolean(visible);
			}
			menuItem1.tag = childNode3.getAttribute("tag");
			this.iterateXMLNodes(menuItem1, childNode3);
			item.addItem(menuItem1);
		}
	}
};
Menu.prototype.setTarget = function (target) {
	this.Target = target;
};
Menu.prototype.getTarget = function () {
	return this.Target;
};
Menu.prototype.setPopupContainer = function (popupContainer) {
	this.PopupContainer = popupContainer;
};
Menu.prototype.getPopupContainer = function () {
	return this.PopupContainer;
};
Menu.prototype.buttonBindMenu = function (item1) {
	var items = item1.getItems();
	var size = items.size();
	if (size > 0) {
		var GroupBoxElement = item1.GroupBoxElement2;
		if (GroupBoxElement == null) {
			GroupBoxElement = initGroupBoxElement(item1);
			item1.GroupBoxElement2 = GroupBoxElement;
		}
		GroupBoxElement.refresh();
		return GroupBoxElement;
	} else {
		return null;
	}
};
Menu.prototype.detroyGroupBoxElement = function () {
	if (this.GroupBoxElement3 != null) {
		this.GroupBoxElement3.hide();
		this.GroupBoxElement3 = null;
	}
};
function initGroupBoxElement(item) {
	var TableElement = document.createElement("TABLE");
	TableElement.style.width = "100%";
	TableElement.cellPadding = 0;
	TableElement.cellSpacing = 0;
	var TbodyElement = document.createElement("TBODY");
	TableElement.appendChild(TbodyElement);
	GroupBoxElement = document.createElement("DIV");
	GroupBoxElement.appendChild(TableElement);
	setComponentDisplay(GroupBoxElement, false);
	document.body.appendChild(GroupBoxElement);
	EventManager.addSystemEvent(TableElement, "onclick", function (event) {
		onclickMenu(event);
	});
	EventManager.addSystemEvent(TableElement, "onmouseover", function (event) {
		onmouseoverMenu(event);
	});
	EventManager.addSystemEvent(TableElement, "onmouseout", function (event) {
		onmouseoutMenu(event);
	});
	GroupBoxElement.id = controlId();
	GroupBoxElement.className = "PopupMenu";
	GroupBoxElement.style.position = "absolute";
	GroupBoxElement.saturnClass = "PopupMenuBox";
	GroupBoxElement.menuitem = item;
	GroupBoxElement.Opened = false;
	GroupBoxElement.ButtonElement4 = null;
	GroupBoxElement.ButtonElement3 = null;
	GroupBoxElement.refresh = refreshMenu;
	GroupBoxElement.show = showMenu;
	GroupBoxElement.hide = hideMenu;
	GroupBoxElement.hideGroupDiv = hideGroupDivMenu;
	GroupBoxElement.expand = expandMenu;
	GroupBoxElement.isMenuItemExpand = isMenuItemExpandMenu;
	GroupBoxElement.isMenuItemHotDisabled = isMenuItemHotDisabledMenu;
	return GroupBoxElement;
}
function refreshMenu() {
	var TbodyElement = this.firstChild.tBodies[0];
	var rowsLength = TbodyElement.rows.length;
	var TrElement, TdElement, ButtonElement, row0;
	var items = this.menuitem.getItems();
	var size = items.size();
	for (var i = 0; i < size; i++) {
		var item = items.get(i);
		if (!item.visible) {
			continue;
		}
		if (i < rowsLength) {
			ButtonElement = TbodyElement.rows[i].cells[0].firstChild;
			row0 = ButtonElement.firstChild.tBodies[0].rows[0];
		} else {
			TdElement = document.createElement("TD");
			ButtonElement = initMenuItem().cloneNode(true);
			ButtonElement.saturnClass = "MenuItem";
			row0 = ButtonElement.firstChild.tBodies[0].rows[0];
			TrElement = document.createElement("TR");
			TdElement.appendChild(ButtonElement);
			TrElement.appendChild(TdElement);
			TbodyElement.appendChild(TrElement);
		}
		var row0Cell0 = row0.cells[0];
		var row0Cell2 = row0.cells[2];
		var row0Cell3 = row0.cells[3];
		var Menu = item.menu;
		if (Menu._onRefreshItem == null || fireSaturnEvent(Menu, "onRefreshItem", [Menu, row0Cell2, item])) {
			row0Cell2.innerText = item.Label;
		}
		var itemIcon;
		if (item.Disabled && item.DisableIcon != null) {
			itemIcon = item.Disabled;
		} else {
			itemIcon = item.Icon;
		}
		if (itemIcon != null) {
			var IMGElement7 = row0Cell0.firstChild;
			var cflag13 = (IMGElement7 != null && IMGElement7.src == itemIcon);
			if (!cflag13) {
				IMGElement7 = document.createElement("IMG");
				IMGElement7.src = itemIcon;
				if (row0Cell0.firstChild != null) {
					row0Cell0.removeChild(row0Cell0.firstChild);
				}
				row0Cell0.appendChild(IMGElement7);
			}
		}
		if (item.Items != null && item.Items.size() > 0) {
			var IMGElement7 = row0Cell3.firstChild;
			var cflag13 = (IMGElement7 != null);
			if (!cflag13) {
				IMGElement7 = document.createElement("IMG");
				IMGElement7.src = __SKIN_PATH + "/menu_indicator.gif";
				row0Cell3.appendChild(IMGElement7);
			}
		} else {
			if (row0Cell3.firstChild != null) {
				row0Cell3.removeChild(row0Cell3.firstChild);
			}
		}
		ButtonElement.menuitem = item;
		if (item.Disabled) {
			ButtonElement.className = "MenuItem_Disabled";
		} else {
			ButtonElement.className = "MenuItem";
		}
	}
}
function showMenu(ParentNode) {
	var Menu = this.menuitem.menu;
	if (ParentNode == null) {
		var GroupBoxElement4 = Menu.GroupBoxElement3;
		if (GroupBoxElement4 != null && GroupBoxElement4.Opened) {
			GroupBoxElement4.hide();
		}
		Menu.GroupBoxElement3 = this;
	} else {
		ParentNode.hideGroupDiv();
		ParentNode.groupDIV = this;
	}
	this.style.zIndex = getzIndex();
	setComponentDisplay(this, true);
	this.Opened = true;
}
function hideGroupDivMenu() {
	if (this.groupDIV != null && this.groupDIV.Opened) {
		this.groupDIV.hide();
		this.groupDIV = null;
	}
}
function hideMenu() {
	var Menu = this.menuitem.menu;
	clearTimeout(Menu.Timeout1);
	clearTimeout(this.Timeout1);
	clearTimeout(this.TimeoutMenu);
	this.ButtonElement4 = null;
	this.ButtonElement3 = null;
	this.hideGroupDiv();
	setComponentDisplay(this, false);
	this.Opened = false;
}
/**
* @description	isMenuItemHotDisabledMenu   判断menuItem的类型
*/
function isMenuItemHotDisabledMenu(ButtonElement) {
	var ItemElement = this.ButtonElement4;
	if (ItemElement != null) {
		if (ItemElement.menuitem.Disabled) {
			ItemElement.className = "MenuItem_Disabled";
		} else {
			ItemElement.className = "MenuItem";
		}
	}
	if (ButtonElement == null) {
		ButtonElement = this.ButtonElement3;
	}
	if (ButtonElement != null) {
		if (ButtonElement.menuitem.Disabled) {
			ButtonElement = null;
		} else {
			ButtonElement.className = "HotMenuItem";
		}
	}
	this.ButtonElement4 = ButtonElement;
}
function expandMenu(ButtonElement) {
	var item = ButtonElement.menuitem;
	if (item.Disabled) {
		return;
	}
	var Menu = item.menu;
	var GroupBoxElement = Menu.buttonBindMenu(item);
	if (GroupBoxElement != null) {
		var ParentNode = getParentNode(ButtonElement, "PopupMenuBox");
		GroupBoxElement.show(ParentNode);
		var absolutePosition = getAbsolutePosition(ButtonElement);
		var x = absolutePosition[0] + ButtonElement.offsetWidth - 1;
		if (x + GroupBoxElement.offsetWidth > document.body.clientWidth) {
			x = absolutePosition[0] - GroupBoxElement.offsetWidth + 1;
		}
		if (x < 0) {
			x = 0;
		}
		GroupBoxElement.style.left = x;
		var y = absolutePosition[1] - 1;
		if (y + GroupBoxElement.offsetHeight > document.body.clientHeight) {
			y = absolutePosition[1] + ButtonElement.offsetHeight - GroupBoxElement.offsetHeight + 1;
		}
		if (y < 0) {
			y = 0;
		}
		GroupBoxElement.style.top = y;
	}
	this.ButtonElement3 = ButtonElement;
}
/**
* @description	isMenuItemExpandMenu   判断menuItem是否可扩展
*/
function isMenuItemExpandMenu() {
	if (this.ButtonElement4 != null) {
		this.expand(this.ButtonElement4);
	}
}
function onclickMenu(event) {
	var target;
	if (browserType == browserType1) {
		target = event.srcElement;
	} else {
		target = event.target;
	}
	var ButtonElement = getParentNode(target, "MenuItem");
	if (ButtonElement != null) {
		var GroupBoxElement = getParentNode(ButtonElement, "PopupMenuBox");
		if (GroupBoxElement != null) {
			if (GroupBoxElement.ButtonElement3 != ButtonElement) {
				GroupBoxElement.expand(ButtonElement);
			}
		}
		var item = ButtonElement.menuitem;
		if (item != null && !item.Disabled) {
			item.click();
		}
	}
}
function onmouseoverMenu(event) {
	var target;
	if (browserType == browserType1) {
		target = event.srcElement;
	} else {
		target = event.target;
	}
	var GroupBoxElement = getParentNode(target, "PopupMenuBox");
	var Menu = GroupBoxElement.menuitem.menu;
	clearTimeout(Menu.Timeout1);
	clearTimeout(GroupBoxElement.Timeout1);
	var ButtonElement = getParentNode(target, "MenuItem");
	if (ButtonElement != null) {
		GroupBoxElement.isMenuItemHotDisabled(ButtonElement);
		if (GroupBoxElement.ButtonElement3 != ButtonElement) {
			GroupBoxElement.TimeoutMenu = setTimeout("document.getElementById(\"" + GroupBoxElement.id + "\").isMenuItemExpand();", 600);
		}
	}
}
function onmouseoutMenu(event) {
	var target;
	if (browserType == browserType1) {
		target = event.srcElement;
	} else {
		target = event.target;
	}
	var GroupBoxElement = getParentNode(target, "PopupMenuBox");
	var Menu = GroupBoxElement.menuitem.menu;
	Menu.Timeout1 = setTimeout("getControl(\"" + Menu.id + "\").detroyGroupBoxElement();", 500);
	var ButtonElement = getParentNode(target, "MenuItem");
	if (ButtonElement != null) {
		var GroupBoxElement = getParentNode(ButtonElement, "PopupMenuBox");
		if (GroupBoxElement != null) {
			clearTimeout(GroupBoxElement.TimeoutMenu);
			GroupBoxElement.Timeout1 = setTimeout("document.getElementById(\"" + GroupBoxElement.id + "\").isMenuItemHotDisabled(null);", 300);
		}
	}
}
saturnJspTag.MenuBarComponent = Class.create();
saturnJspTag.MenuBarComponent.prototype = Object.extend(new saturnJspTag.Base(), {initialize:function (id) {
	this.BarElement = document.getElementById(id);
	this.BarElement.menu = null;
	this.BarElement.ShowBorder = true;
	this.BarElement.FitWidth = false;
	this.BarElement.ButtonElement4 = null;
	this.BarElement.ButtonElement3 = null;
}, destroy:function () {
	this.BarElement.ButtonElement4 = null;
	this.BarElement.ButtonElement3 = null;
	this.BarElement.TrElement14 = null;
	this.BarElement.BlankPanel = null;
}, activate:function (menubar) {
	if (!this.BarElement.uMap02) {
		this.init(menubar);
		this.refresh();
		this.BarElement.uMap02 = true;
	}
}, getMenu:function () {
	return getControl(this.BarElement.menu);
}, setMenu:function (Menu) {
	this.BarElement.menu = Menu;
	if (this.BarElement.uMap02) {
		this.refresh();
	}
}, isShowBorder:function () {
	return this.BarElement.ShowBorder;
}, setShowBorder:function (showBorder) {
	this.BarElement.ShowBorder = showBorder;
}, isFitWidth:function () {
	return this.BarElement.FitWidth;
}, getBlankPanel:function () {
	return this.BarElement.BlankPanel;
}, init:function (menubar) {
	this.BarElement.className = "MenuBar";
	this.BarElement.cellPadding = getPreferenceSetting("__MenuBar_CellPadding");
	this.BarElement.border = getPreferenceSetting("__MenuBar_BorderWidth");
	this.BarElement.borderColor = getPreferenceSetting("__MenuBar_BorderColor");
	var TbodyElement = document.createElement("TBODY");
	var TrElement = document.createElement("TR");
	this.BarElement.TrElement14 = TrElement;
	TbodyElement.appendChild(TrElement);
	this.BarElement.appendChild(TbodyElement);
	if (!this.BarElement.ShowBorder) {
		this.BarElement.style.borderWidth = 0;
	}
	var BarElement = this.BarElement;
	EventManager.addSystemEvent(BarElement, "onclick", function (event) {
		menubar.onclickMenuBar(BarElement, event, menubar);
	});
	EventManager.addSystemEvent(BarElement, "onmouseover", function (event) {
		menubar.onmouseoverMenuBar(BarElement, event, menubar);
	});
	EventManager.addSystemEvent(BarElement, "onmouseout", function (event) {
		menubar.onmouseoutMenuBar(BarElement, event, menubar);
	});
}, refresh:function () {
	function setDisabledButton(Menu, item, ButtonElement) {
		ButtonElement.saturnClass = "MenuBarButton";
		if (item.Disabled) {
			ButtonElement.className = "Button_Disabled";
		} else {
			ButtonElement.className = "Button";
		}
		ButtonElement.style.height = "100%";
		var TrElement, TdElement;
		TrElement = document.createElement("TR");
		if (item.Icon != null) {
			TdElement = document.createElement("TD");
			TdElement.innerHTML = "<IMG src=\"" + item.Icon + "\">";
			TrElement.appendChild(TdElement);
		}
		TdElement = document.createElement("TD");
		TdElement.style.whiteSpace = "nowrap";
		TdElement.align = "center";
		TdElement.style.width = "100%";
		if (Menu._onRefreshItem == null || fireSaturnEvent(Menu, "onRefreshItem", [Menu, TdElement, item])) {
			TdElement.innerText = item.Label;
		}
		TrElement.appendChild(TdElement);
		var TbodyElement = document.createElement("TBODY");
		TbodyElement.appendChild(TrElement);
		var TableElement = document.createElement("TABLE");
		TableElement.style.height = "100%";
		TableElement.cellSpacing = 0;
		TableElement.cellPadding = 1;
		TableElement.appendChild(TbodyElement);
		ButtonElement.appendChild(TableElement);
		ButtonElement.menuitem = item;
	}
	var TrElement = this.BarElement.TrElement14;
	for (var i = TrElement.childNodes.length - 1; i >= 0; i--) {
		TrElement.deleteCell(i);
	}
	var Menu = this.getMenu();
	if (Menu != null) {
		var items = Menu.TopItem.getItems();
		var size = items.size();
		for (var i = 0; i < size; i++) {
			var item = items.get(i);
			if (!item.visible) {
				continue;
			}
			var TdElement = document.createElement("TD");
			var ButtonElement = document.createElement("DIV");
			setDisabledButton(Menu, item, ButtonElement);
			TdElement.appendChild(ButtonElement);
			TrElement.appendChild(TdElement);
		}
		if (!this.BarElement.FitWidth) {
			var TdElement = document.createElement("TD");
			TdElement.saturnClass = "MenuBarBlank";
			TdElement.align = "right";
			TdElement.style.width = "100%";
			this.BarElement.BlankPanel = TdElement;
			TrElement.appendChild(TdElement);
		}
	}
}, isButtonHotDisabled:function (ButtonElement) {
	if (this.BarElement.ButtonElement4 == ButtonElement) {
		return;
	}
	var ItemElement = this.BarElement.ButtonElement4;
	if (ItemElement != null) {
		if (ItemElement.menuitem.Disabled) {
			ItemElement.className = "Button_Disabled";
		} else {
			ItemElement.className = "Button";
		}
	}
	if (ButtonElement == null) {
		ButtonElement = this.BarElement.ButtonElement3;
	}
	if (ButtonElement != null) {
		if (ButtonElement.menuitem.Disabled) {
			ButtonElement = null;
		} else {
			ButtonElement.className = "HotButton";
		}
	}
	this.BarElement.ButtonElement4 = ButtonElement;
}, getMenuButtonAbsolutePosition:function (ButtonElement, menubar) {
	if (this.BarElement.ButtonElement3 == ButtonElement) {
		return;
	}
	var item = ButtonElement.menuitem;
	if (item.Disabled) {
		return;
	}
	clearInterval(this.BarElement.menubarInterval);
	var Menu = this.getMenu();
	Menu.detroyGroupBoxElement();
	var intervalSymbel;
	var GroupBoxElement = Menu.buttonBindMenu(item);
	if (GroupBoxElement != null) {
		GroupBoxElement.show();
		intervalSymbel = 300;
		var absolutePosition = getAbsolutePosition(ButtonElement);
		var x = absolutePosition[0];
		if (x + GroupBoxElement.offsetWidth > document.body.clientWidth) {
			x = absolutePosition[0] + ButtonElement.offsetWidth - GroupBoxElement.offsetWidth;
		}
		if (x < 0) {
			x = 0;
		}
		GroupBoxElement.style.left = x;
		var y = absolutePosition[1] + ButtonElement.offsetHeight + 2;
		if (y + GroupBoxElement.offsetHeight > document.body.clientHeight) {
			y = absolutePosition[1] - GroupBoxElement.offsetHeight - 2;
		}
		if (y < 0) {
			y = 0;
		}
		GroupBoxElement.style.top = y;
	} else {
		intervalSymbel = 1500;
	}
	this.BarElement.menubarInterval = setInterval("menubar.stopInterval();", intervalSymbel);
	this.BarElement.ButtonElement3 = ButtonElement;
}, stopInterval:function () {
	var cflag14 = false;
	var Menu = this.getMenu();
	var GroupBoxElement = Menu.GroupBoxElement3;
	if (GroupBoxElement != null) {
		cflag14 = (!GroupBoxElement.Opened);
	} else {
		cflag14 = true;
	}
	if (cflag14) {
		clearInterval(this.BarElement.menubarInterval);
		this.BarElement.ButtonElement3 = null;
		this.isButtonHotDisabled(null);
	}
}, onclickMenuBar:function (BarElement, event, menubar) {
	var target;
	if (browserType == browserType1) {
		target = event.srcElement;
	} else {
		target = event.target;
	}
	if (target.saturnClass == "MenuBarBlank") {
		return;
	}
	var ButtonElement = getParentNode(target, "MenuBarButton");
	if (ButtonElement != null) {
		var Menu = menubar.getMenu();
		var item = ButtonElement.menuitem;
		if (item.Disabled) {
			return;
		}
		menubar.getMenuButtonAbsolutePosition(ButtonElement, menubar);
		item.click();
	}
}, onmouseoverMenuBar:function (BarElement, event, menubar) {
	var Menu = menubar.getMenu();
	clearTimeout(Menu.Timeout1);
	var target;
	if (browserType == browserType1) {
		target = event.srcElement;
	} else {
		target = event.target;
	}
	var ButtonElement = getParentNode(target, "MenuBarButton");
	if (ButtonElement != null) {
		clearTimeout(BarElement.Timeout1);
		menubar.isButtonHotDisabled(ButtonElement);
		if (BarElement.ButtonElement3 != null) {
			var item = ButtonElement.menuitem;
			menubar.getMenuButtonAbsolutePosition(ButtonElement);
		}
	}
}, onmouseoutMenuBar:function (BarElement, event, menubar) {
	var target;
	if (browserType == browserType1) {
		target = event.srcElement;
	} else {
		target = event.target;
	}
	var ButtonElement = getParentNode(target, "MenuBarButton");
	if (ButtonElement != null) {
		BarElement.Timeout1 = setTimeout("menubar.isButtonHotDisabled(null);", 300);
	}
	var Menu = menubar.getMenu();
	Menu.Timeout1 = setTimeout("getControl(\"" + Menu.id + "\").detroyGroupBoxElement();", 500);
}});
function OutlookBarGroup() {
	this.Div = null;
	this.viewFlag = false;
}
OutlookBarGroup.prototype.destroy = function () {
	this.$vv = null;
	this.$2D = null;
	this.groupTrElement = null;
	this.TrElement15 = null;
	this.Div = null;
	this.groupBarElement = null;
};
OutlookBarGroup.prototype.getName = function () {
	return this.name01;
};
OutlookBarGroup.prototype.setDisabled = function (disabled) {
	this.Disabled = disabled;
};
OutlookBarGroup.prototype.getDiv = function () {
	return this.Div;
};
OutlookBarGroup.prototype.getTag = getTag;
OutlookBarGroup.prototype.setTag = setTag;
function DefaultOutlookBarGroup(name) {
	this.saturnClass = "DefaultOutlookBarGroup";
	this.name01 = name;
	this.Label = name;
	this.Icon = null;
	this.Disabled = false;
	this.visible = true;
	this.Padding = null;
}
DefaultOutlookBarGroup.prototype = new OutlookBarGroup();
DefaultOutlookBarGroup.prototype.getLabel = function () {
	return this.Label;
};
DefaultOutlookBarGroup.prototype.setLabel = function (label) {
	this.Label = label;
};
DefaultOutlookBarGroup.prototype.getIcon = function () {
	return this.Icon;
};
DefaultOutlookBarGroup.prototype.setIcon = function (IMGElement7) {
	this.Icon = IMGElement7;
};
DefaultOutlookBarGroup.prototype.isVisible = function () {
	return this.visible;
};
DefaultOutlookBarGroup.prototype.setVisible = function (visible) {
	this.visible = visible;
};
DefaultOutlookBarGroup.prototype.isDisabled = function () {
	return this.Disabled;
};
DefaultOutlookBarGroup.prototype.setDisabled = function (disabled) {
	this.Disabled = disabled;
};
DefaultOutlookBarGroup.prototype.getPadding = function () {
	return this.Padding;
};
DefaultOutlookBarGroup.prototype.setPadding = function (padding) {
	this.Padding = padding;
};
DefaultOutlookBarGroup.prototype.setDIVProperties = function () {
	if (this.viewFlag) {
		return;
	}
	var DIVElement = document.getElementById(this.groupBarElement.id + "_" + this.name01);
	if (DIVElement == null) {
		DIVElement = document.createElement("DIV");
	}
	DIVElement.className = "Group";
	DIVElement.style.overflow = "hidden";
	DIVElement.style.width = "100%";
	DIVElement.style.height = "100%";
	DIVElement.style.display = "";
	if (this.Padding != null) {
		DIVElement.style.padding = this.Padding;
	}
	this.Div = DIVElement;
	this._initChildren = null;
	this.viewFlag = true;
};
var viewMode1 = "icon";
var viewMode2 = "list";
function MenuOutlookBarGroup(name) {
	this.saturnClass = "MenuOutlookBarGroup";
	this.name01 = name;
	this.menuitem = null;
	this.ViewMode = viewMode1;
}
MenuOutlookBarGroup.prototype = new OutlookBarGroup();
MenuOutlookBarGroup.prototype.getMenuItem = function () {
	return this.menuitem;
};
MenuOutlookBarGroup.prototype.setMenuItem = function (item) {
	this.menuitem = item;
};
MenuOutlookBarGroup.prototype.getLabel = function () {
	return this.menuitem.Label;
};
MenuOutlookBarGroup.prototype.setLabel = function (label) {
	this.menuitem.Label = label;
};
MenuOutlookBarGroup.prototype.getIcon = function () {
	return this.menuitem.Icon;
};
MenuOutlookBarGroup.prototype.setIcon = function (IMGElement7) {
	this.menuitem.Icon = IMGElement7;
};
MenuOutlookBarGroup.prototype.isVisible = function () {
	return this.menuitem.visible;
};
MenuOutlookBarGroup.prototype.setVisible = function (visible) {
	this.menuitem.visible = visible;
};
MenuOutlookBarGroup.prototype.isDisabled = function () {
	return this.menuitem.Disabled;
};
MenuOutlookBarGroup.prototype.setDisabled = function (disabled) {
	this.menuitem.Disabled = disabled;
};
MenuOutlookBarGroup.prototype.getViewMode = function () {
	return this.ViewMode;
};
MenuOutlookBarGroup.prototype.setViewMode = function (viewMode) {
	this.ViewMode = viewMode;
};
MenuOutlookBarGroup.prototype.refresh = function () {
	var DIVElement = this.Div;
	var item1 = this.menuitem;
	var TrElement, TdElement, ButtonElement, IMGElement4, label;
	var TbodyElement = document.createElement("TBODY");
	var items = item1.getItems();
	var size = items.size();
	for (var i = 0; i < size; i++) {
		var item = items.get(i);
		if (!item.visible) {
			continue;
		}
		var TrElement;
		if (this.ViewMode == viewMode1) {
			TrElement = initOutlookBarSubButton().cloneNode(true);
		} else {
			TrElement = initOutlookBarSubButton1().cloneNode(true);
		}
		var ButtonElement = TrElement.firstChild.firstChild;
		ButtonElement.menuitem = item;
		if (item.Disabled) {
			ButtonElement.className = "SubButton_Disabled";
		} else {
			ButtonElement.className = "SubButton";
		}
		var Menu = item.menu;
		if (this.ViewMode == viewMode1) {
			var tBody0 = ButtonElement.firstChild.tBodies[0];
			var label = tBody0.rows[1].cells[0].firstChild;
			if (Menu._onRefreshItem == null || fireSaturnEvent(Menu, "onRefreshItem", [Menu, label, item])) {
				label.innerText = item.Label;
			}
			var IMGElement7 = tBody0.rows[0].cells[0].firstChild;
			if (item.Icon != null) {
				IMGElement7.src = item.Icon;
			} else {
				IMGElement7.src = __SKIN_PATH + "/outlookbar_defaulticon.gif";
			}
			var row0Cell3 = tBody0.rows[0].cells[1];
			if (item.Items != null && item.Items.size() > 0) {
				var IMGElement7 = row0Cell3.firstChild;
				var cflag13 = (IMGElement7 != null);
				if (!cflag13) {
					IMGElement7 = document.createElement("IMG");
					IMGElement7.src = __SKIN_PATH + "/outlookbar_indicator.gif";
					row0Cell3.appendChild(IMGElement7);
				}
			} else {
				if (row0Cell3.firstChild != null) {
					row0Cell3.removeChild(row0Cell3.firstChild);
				}
			}
		} else {
			var tBody0 = ButtonElement.firstChild.tBodies[0];
			var label = tBody0.rows[0].cells[1].firstChild;
			if (Menu._onRefreshItem == null || fireSaturnEvent(Menu, "onRefreshItem", [Menu, label, item])) {
				label.innerText = item.Label;
			}
			var IMGElement7 = tBody0.rows[0].cells[0].firstChild;
			if (item.Icon != null) {
				IMGElement7.src = item.Icon;
				IMGElement7.style.display = "";
			} else {
				IMGElement7.style.display = "none";
			}
			var row0Cell3 = tBody0.rows[0].cells[2];
			if (item.Items != null && item.Items.size() > 0) {
				var IMGElement7 = row0Cell3.firstChild;
				var cflag13 = (IMGElement7 != null);
				if (!cflag13) {
					IMGElement7 = document.createElement("IMG");
					IMGElement7.src = __SKIN_PATH + "/outlookbar_indicator.gif";
					row0Cell3.appendChild(IMGElement7);
				}
			} else {
				if (row0Cell3.firstChild != null) {
					row0Cell3.removeChild(row0Cell3.firstChild);
				}
			}
		}
		TbodyElement.appendChild(TrElement);
	}
	var TableElement = document.createElement("TABLE");
	TableElement.style.width = "100%";
	TableElement.appendChild(TbodyElement);
	DIVElement.appendChild(TableElement);
};
MenuOutlookBarGroup.prototype.setDIVProperties = function () {
	if (this.viewFlag) {
		return;
	}
	var DIVElement = document.createElement("DIV");
	DIVElement.className = (this.ViewMode == viewMode1) ? "IconGroup" : "ListGroup";
	DIVElement.style.overflow = "hidden";
	DIVElement.style.width = "100%";
	DIVElement.style.height = "100%";
	this.Div = DIVElement;
	this.refresh();
	this.viewFlag = true;
};
saturnJspTag.OutlookBarComponent = Class.create();
saturnJspTag.OutlookBarComponent.prototype = Object.extend(new saturnJspTag.Base(), {initialize:function (id) {
	this.BarElement = document.getElementById(id);
	this.BarElement.menu = null;
	this.BarElement.barMap = new HashList();
	this.BarElement.RadioGroupElement2 = null;
	this.BarElement.Animated = true;
}, destroy:function () {
	var uMap02 = this.BarElement.barMap.uArray3;
	for (var i = 0; i < uMap02.length; i++) {
		var RadioGroupElement = uMap02[i];
		RadioGroupElement.destroy();
	}
	this.BarElement.barMap.clear();
	this.BarElement.IMGElement10 = null;
	this.BarElement.IMGElement9 = null;
	this.BarElement.TbodyElement4 = null;
}, activate:function () {
	if (!this.BarElement.uMap02) {
		this.setItemGroup();
		this.init(outlookbar);
		this.refresh();
		this.BarElement.uMap02 = true;
		var RadioGroupElement = this.BarElement.RadioGroupElement2;
		this.BarElement.RadioGroupElement2 = null;
		this.setCurrentGroup(RadioGroupElement, outlookbar);
		fireSaturnEvent(this, "onActive", [this]);
	}
}, getMenu:function () {
	return getControl(this.BarElement.menu);
}, setMenu:function (Menu) {
	this.BarElement.menu = Menu;
	if (this.BarElement.uMap02) {
		this.refresh();
	}
}, addGroup:function (RadioGroupElement) {
	var size = this.BarElement.barMap.size();
	this.BarElement.barMap.put(RadioGroupElement.name01, RadioGroupElement);
	RadioGroupElement.groupBarElement = this.BarElement;
	if (size == 0) {
		this.setCurrentGroup(RadioGroupElement);
	}
	return RadioGroupElement;
}, getGroup:function (name) {
	return this.BarElement.barMap.get(name);
}, removeGroup:function (RadioGroupElement) {
	if (typeof (RadioGroupElement) == "string") {
		RadioGroupElement = this.getGroup(RadioGroupElement);
		if (RadioGroupElement == null) {
			return null;
		}
	}
	this.BarElement.barMap.remove(RadioGroupElement.name01);
	return RadioGroupElement;
}, getGroupCount:function () {
	return this.BarElement.barMap.size();
}, setItemGroup:function () {
	var uMap02 = new HashList();
	var barMap1 = this.BarElement.barMap;
	var RadioGroupElement3 = this.BarElement.RadioGroupElement2;
	var cflag15 = false;
	var Menu = this.getMenu();
	if (Menu != null) {
		var items = Menu.TopItem.getItems();
		var size = items.size();
		for (var i = 0; i < size; i++) {
			var item = items.get(i);
			var RadioGroupElement = barMap1.remove(item.name01);
			if (RadioGroupElement == null) {
				RadioGroupElement = new MenuOutlookBarGroup(item.name01);
				RadioGroupElement.groupBarElement = this.BarElement;
			}
			if (typeof (RadioGroupElement3) == "string") {
				if (RadioGroupElement3 == item.name01) {
					cflag15 = true;
				}
			} else {
				if (RadioGroupElement3 == RadioGroupElement) {
					cflag15 = true;
				}
			}
			if (typeof (RadioGroupElement.setMenuItem) == "function") {
				RadioGroupElement.setMenuItem(item);
			}
			uMap02.put(RadioGroupElement.name01, RadioGroupElement);
		}
	}
	var hashArray = barMap1.uArray3;
	for (var i = 0; i < hashArray.length; i++) {
		var RadioGroupElement = hashArray[i];
		if (RadioGroupElement.saturnClass == "DefaultOutlookBarGroup") {
			uMap02.put(RadioGroupElement.name01, RadioGroupElement);
		} else {
			RadioGroupElement.destroy();
		}
	}
	barMap1.clear();
	if (!cflag15) {
		this.setCurrentGroup(uMap02.get(0));
	}
	this.BarElement.barMap = uMap02;
}, init:function (outlookbar) {
	this.BarElement.className = "OutlookBar";
	this.BarElement.cellPadding = 0;
	this.BarElement.cellSpacing = 1;
	var TbodyElement = document.createElement("TBODY");
	this.BarElement.TbodyElement4 = TbodyElement;
	this.BarElement.appendChild(TbodyElement);
	var BarElement = this.BarElement;
	EventManager.addSystemEvent(this.BarElement, "onclick", function (event) {
		outlookbar.onclickOutlookBar(BarElement, event, outlookbar);
	});
	EventManager.addSystemEvent(this.BarElement, "onmouseover", function (event) {
		outlookbar.onmouseoverOutlookBar(BarElement, event);
	});
	EventManager.addSystemEvent(this.BarElement, "onmouseout", function (event) {
		outlookbar.onmouseoutOutlookBar(BarElement, event);
	});
}, isAnimated:function () {
	return this.BarElement.Animated;
}, setAnimated:function (animated) {
	this.BarElement.Animated = animated;
}, refresh:function () {
	var TbodyElement = this.BarElement.TbodyElement4;
	for (var i = TbodyElement.childNodes.length - 1; i >= 0; i--) {
		TbodyElement.removeChild(TbodyElement.childNodes[i]);
	}
	var Menu = this.getMenu();
	var menuItem = null;
	if (Menu != null) {
		menuItem = Menu.TopItem;
	}
	var uMap02 = this.BarElement.barMap.uArray3;
	for (var i = 0; i < uMap02.length; i++) {
		var RadioGroupElement = uMap02[i];
		var TrElement = document.createElement("TR");
		var TdElement = document.createElement("TD");
		TdElement.align = "center";
		var ButtonElement = document.createElement("DIV");
		ButtonElement.saturnClass = "OutlookBarButton";
		ButtonElement.className = "Button";
		ButtonElement.style.width = "100%";
		ButtonElement.style.height = "100%";
		ButtonElement.style.whiteSpace = "nowrap";
		if (Menu != null) {
			var item = menuItem.getItem(RadioGroupElement.name01);
			if (Menu._onRefreshItem == null || fireSaturnEvent(Menu, "onRefreshItem", [Menu, ButtonElement, item])) {
				ButtonElement.innerText = RadioGroupElement.getLabel();
			}
		} else {
			ButtonElement.innerText = RadioGroupElement.getLabel();
		}
		ButtonElement.RadioGroupElement1 = RadioGroupElement;
		TdElement.appendChild(ButtonElement);
		TrElement.appendChild(TdElement);
		TbodyElement.appendChild(TrElement);
		RadioGroupElement.groupTrElement = TrElement;
		var TrElement = document.createElement("TR");
		TrElement.id = controlId();
		var TdElement = document.createElement("TD");
		if (this.BarElement.RadioGroupElement2 == RadioGroupElement) {
			TrElement.style.display = "";
			TrElement.style.height = "100%";
		} else {
			TrElement.style.display = "none";
			TrElement.style.height = "0%";
		}
		TrElement.appendChild(TdElement);
		TbodyElement.appendChild(TrElement);
		RadioGroupElement.TrElement15 = TrElement;
		this.setElementVisible();
	}
}, setCurrentGroup:function (RadioGroupElement, outlookbar) {
	if (this.BarElement.uMap02) {
		var RadioGroupElement3 = this.BarElement.RadioGroupElement2;
		var RadioGroupElement4;
		if (typeof (RadioGroupElement3) == "string") {
			RadioGroupElement4 = this.BarElement.barMap.get(RadioGroupElement3);
		} else {
			RadioGroupElement4 = RadioGroupElement3;
		}
		var RadioGroupElement5;
		if (typeof (RadioGroupElement) == "string") {
			RadioGroupElement5 = this.BarElement.barMap.get(RadioGroupElement);
		} else {
			RadioGroupElement5 = RadioGroupElement;
		}
		if (RadioGroupElement5 != null) {
			if (RadioGroupElement5.isDisabled()) {
				return;
			}
			var cflag5;
			if (!RadioGroupElement5.viewFlag) {
				RadioGroupElement5.setDIVProperties();
				cflag5 = RadioGroupElement5.TrElement15;
				var DIVElement = RadioGroupElement5.getDiv();
				cflag5.cells[0].appendChild(DIVElement);
			} else {
				cflag5 = RadioGroupElement5.TrElement15;
			}
			if (RadioGroupElement5 != RadioGroupElement4) {
				if (RadioGroupElement4 != null) {
					if (this.BarElement.$xk) {
						clearTimeout(this.BarElement.$xk);
						this.BarElement.$xk = 0;
					}
					var trEle = RadioGroupElement4.TrElement15;
					cflag5.style.display = "";
					if (this.BarElement.Animated) {
						setTimeout("outlookbar.setElementPosition(outlookbar, " + "document.getElementById(\"" + trEle.id + "\"), " + "document.getElementById(\"" + cflag5.id + "\"), 20,outlookbar)", 0);
					} else {
						trEle.style.display = "none";
						trEle.style.height = "0%";
						cflag5.style.display = "";
						cflag5.style.height = "100%";
						this.setElementVisible();
					}
				} else {
					cflag5.style.display = "";
					cflag5.style.height = "100%";
					this.setElementVisible();
				}
			}
		}
		this.BarElement.RadioGroupElement2 = RadioGroupElement5;
	} else {
		this.BarElement.RadioGroupElement2 = RadioGroupElement;
	}
}, setElementPosition:function (BarElement, trEle, cflag5, absolutePosition, outlookbar) {
	if (absolutePosition >= 100) {
		trEle.style.display = "none";
		trEle.style.height = "0%";
		cflag5.style.display = "";
		cflag5.style.height = "100%";
		BarElement.setElementVisible();
	} else {
		trEle.style.height = (100 - absolutePosition) + "%";
		cflag5.style.height = absolutePosition + "%";
		setTimeout("outlookbar.setElementPosition(outlookbar, " + "document.getElementById(\"" + trEle.id + "\"), " + "document.getElementById(\"" + cflag5.id + "\"), " + (absolutePosition + 20) + ")", 20);
	}
}, onmouseover1OutlookBar:function () {
	var IMGElement5, IMGElement6;
	if (this.BarElement.IMGElement10 == null) {
		IMGElement5 = document.createElement("DIV");
		IMGElement5.saturnClass = "OutlookBarScrollButton1";
		IMGElement5.className = "ScrollButton";
		IMGElement5.style.position = "absolute";
		IMGElement5.style.zIndex = getzIndex();
		setComponentVisible(IMGElement5, false);
		IMGElement5.innerHTML = "<IMG src=\"" + __SKIN_PATH + "/outlookbar_btn1.gif\">";
		var BarElement = this.BarElement;
		EventManager.addSystemEvent(IMGElement5, "onclick", function (event) {
			onclickOutlookBar1(BarElement, IMGElement5, event);
		});
		this.BarElement.IMGElement10 = IMGElement5;
	}
	if (this.BarElement.IMGElement9 == null) {
		IMGElement6 = document.createElement("DIV");
		IMGElement6.saturnClass = "OutlookBarScrollButton2";
		IMGElement6.className = "ScrollButton";
		IMGElement6.style.position = "absolute";
		IMGElement6.style.zIndex = getzIndex();
		setComponentVisible(IMGElement6, false);
		IMGElement6.innerHTML = "<IMG src=\"" + __SKIN_PATH + "/outlookbar_btn2.gif\">";
		var BarElement = this.BarElement;
		EventManager.addSystemEvent(IMGElement6, "onclick", function (event) {
			onclickOutlookBar1(BarElement, IMGElement6, event);
		});
		this.BarElement.IMGElement9 = IMGElement6;
	}
	return [this.BarElement.IMGElement10, this.BarElement.IMGElement9];
}, setElementVisible:function () {
	if (!this.BarElement.uMap02) {
		return;
	}
	var cArray04 = this.onmouseover1OutlookBar();
	var IMGElement5 = cArray04[0];
	var IMGElement6 = cArray04[1];
	if (this.BarElement.RadioGroupElement2 != null) {
		var DIVElement2 = this.BarElement.RadioGroupElement2.TrElement15.cells[0].firstChild;
		if (DIVElement2 == null) {
			return;
		}
		if (DIVElement2.offsetHeight < DIVElement2.scrollHeight) {
			if (DIVElement2.scrollTop > 0) {
				DIVElement2.appendChild(IMGElement5);
				setComponentVisible(IMGElement5, true);
				IMGElement5.style.left = DIVElement2.offsetWidth - IMGElement5.offsetWidth - 1;
				IMGElement5.style.top = DIVElement2.scrollTop + 2;
			} else {
				setComponentVisible(IMGElement5, false);
			}
			if (DIVElement2.scrollTop + DIVElement2.clientHeight < DIVElement2.scrollHeight) {
				DIVElement2.appendChild(IMGElement6);
				setComponentVisible(IMGElement6, true);
				IMGElement6.style.left = DIVElement2.offsetWidth - IMGElement6.offsetWidth - 1;
				IMGElement6.style.top = DIVElement2.scrollTop + DIVElement2.offsetHeight - IMGElement6.offsetHeight - 1;
			} else {
				setComponentVisible(IMGElement6, false);
			}
		} else {
			setComponentVisible(IMGElement5, false);
			setComponentVisible(IMGElement6, false);
		}
	}
}, onResize:function () {
	if (!this.BarElement.uMap02) {
		return;
	}
	if (this.BarElement.Timeout2) {
		clearTimeout(this.BarElement.Timeout2);
	}
	this.BarElement.Timeout2 = setTimeout("var BarElement = document.getElementById(\"" + this.BarElement.id + "\");" + "if (BarElement != null) BarElement.setTabSetScrollBarDisplay()", 150);
}, setTabSetScrollBarDisplay:function () {
	this.setElementVisible();
}, onclickOutlookBar1:function (BarElement, ButtonElement, event) {
	if (BarElement.RadioGroupElement2 != null) {
		var DIVElement2 = BarElement.RadioGroupElement2.TrElement15.cells[0].firstChild;
		if (ButtonElement.saturnClass == "OutlookBarScrollButton1") {
			DIVElement2.scrollTop = DIVElement2.scrollTop - 100;
		} else {
			DIVElement2.scrollTop = DIVElement2.scrollTop + 100;
		}
	}
	BarElement.setElementVisible();
}, onclickOutlookBar:function (BarElement, event, outlookbar) {
	var target;
	if (browserType == browserType1) {
		target = event.srcElement;
	} else {
		target = event.target;
	}
	var ButtonElement = getParentNode(target, "OutlookBarButton");
	if (ButtonElement != null) {
		var RadioGroupElement = ButtonElement.RadioGroupElement1;
		if (RadioGroupElement != BarElement.RadioGroupElement2) {
			outlookbar.setCurrentGroup(RadioGroupElement, outlookbar);
			var item = RadioGroupElement.menuitem;
			if (item != null) {
				item.click();
			}
		}
	} else {
		ButtonElement = getParentNode(target, "OutlookBarSubButton");
		if (ButtonElement != null) {
			var item = ButtonElement.menuitem;
			if (item.Disabled) {
				return;
			}
			var Menu = item.menu;
			var GroupBoxElement = Menu.buttonBindMenu(item);
			if (GroupBoxElement != null) {
				GroupBoxElement.show();
				var absolutePosition = getAbsolutePosition(ButtonElement);
				var x = absolutePosition[0] + ButtonElement.offsetWidth - 2;
				if (x + GroupBoxElement.offsetWidth > document.body.clientWidth) {
					x = absolutePosition[0] - GroupBoxElement.offsetWidth + 2;
				}
				if (x < 0) {
					x = 0;
				}
				GroupBoxElement.style.left = x;
				var y = absolutePosition[1];
				if (y + GroupBoxElement.offsetHeight > document.body.clientHeight) {
					y = absolutePosition[1] + ButtonElement.offsetHeight - GroupBoxElement.offsetHeight;
					if (y + GroupBoxElement.offsetHeight > document.body.clientHeight) {
						y = document.body.clientHeight - GroupBoxElement.offsetHeight;
					}
				}
				if (y < 0) {
					y = 0;
				}
				GroupBoxElement.style.top = y;
				GroupBoxElement.Timeout1 = setTimeout("getControl(\"" + Menu.id + "\").detroyGroupBoxElement();", 1000);
			}
			item.click();
		}
	}
}, onmouseoverOutlookBar:function (BarElement, event) {
	var target;
	if (browserType == browserType1) {
		target = event.srcElement;
	} else {
		target = event.target;
	}
	var ButtonElement = getParentNode(target, "OutlookBarButton");
	if (ButtonElement != null) {
		ButtonElement.className = "HotButton";
	} else {
		ButtonElement = getParentNode(target, "OutlookBarSubButton");
		if (ButtonElement != null && !ButtonElement.menuitem.Disabled) {
			ButtonElement.className = "HotSubButton";
		}
	}
}, onmouseoutOutlookBar:function (BarElement, event) {
	var target;
	if (browserType == browserType1) {
		target = event.srcElement;
	} else {
		target = event.target;
	}
	var ButtonElement = getParentNode(target, "OutlookBarButton");
	if (ButtonElement != null) {
		ButtonElement.className = "Button";
	} else {
		ButtonElement = getParentNode(target, "OutlookBarSubButton");
		if (ButtonElement != null) {
			if (ButtonElement.menuitem.Disabled) {
				ButtonElement.className = "SubButton_Disabled";
			} else {
				ButtonElement.className = "SubButton";
			}
		}
	}
}});
/**
* @title:			Tree
* @description:		树型表格
*/
function TreeNode() {
    this.Id= null;//TODO:chenyan 加了树节点的id
	this.Icon = null;
	this.ExpandedIcon = null;
	this.Checkable = false;
	this.Checked = false;
	this.tag = null;
	this.Nodes = null;
	this.HasChild = true;
	this.Expanded = false;
	this._parent = null;
	this.Tree = null;
	this.CurrentCell = null;
	this.hasExpanded = false;
} 			
TreeNode.prototype.toString = function () {

 
	return this.getLabel() + "\nlevel: " + this.getLevel();
};
TreeNode.prototype.destroy = function () {
	if (this.Nodes != null) {
		var messageNode = this.Nodes.firstNode;
		while (messageNode != null) {
			messageNode.destroy();
			messageNode = messageNode.priviousElement;
		}
	}
	this._parent = null;
	this.CurrentCell = null;
	this.Tree = null;
};
TreeNode.prototype.getLevel = function () {

     //alert("dddd");
	var nodeLevel = 0;
	//alert(this._parent+"   _parent");
	var _parent = this._parent;
	while (_parent != null) {
		_parent = _parent._parent;
		nodeLevel++;
	}
	return nodeLevel;
};
TreeNode.prototype.getIcon = function () {
	return this.Icon;
};
TreeNode.prototype.setIcon = function (IMGElement7) {
	this.Icon = IMGElement7;
};
TreeNode.prototype.getExpandedIcon = function () {
	return this.ExpandedIcon;
};
TreeNode.prototype.setExpandedIcon = function (expandedIcon) {
	this.ExpandedIcon = expandedIcon;
};
TreeNode.prototype.isCheckable = function () {
	return this.Checkable;
};
TreeNode.prototype.setCheckable = function (checkable) {
	this.Checkable = checkable;
};
TreeNode.prototype.isChecked = function () {
	return this.Checked;
};
TreeNode.prototype.setChecked = function (checked) {
	this.Checked = checked;
};
TreeNode.prototype.isHasChild = function () {
	return this.hasChild;
};
TreeNode.prototype.setHasChild = function (hasChild) {
	this.HasChild = hasChild;
};



TreeNode.prototype.setId = function (id) {
//TODO:chenyan 加了设置树节点id的方法
	this.Id = id;
};
TreeNode.prototype.getId = function () {
//TODO:chenyan 加了得到树节点id的方法
	return this.Id;
};




TreeNode.prototype.getTag = getTag;
TreeNode.prototype.setTag = setTag;
TreeNode.prototype.isExpanded = function () {
	return this.Expanded;
};
TreeNode.prototype.setExpandedTreeNode = function (expanded) {
	this.Expanded = expanded;
	if (expanded) {
		this.hasExpanded = true;
	}
};
TreeNode.prototype.setExpanded = function (expanded, tree) {
	var TreeElement = this.Tree;
	if (TreeElement != null) {
		if (expanded) {
			tree.expandNode(this);
		} else {
			tree.collapseNode(this);
		}
	} else {
		this.setExpandedTreeNode(expanded);
	}
};
TreeNode.prototype.getParent = function () {
	return this._parent;
};
TreeNode.prototype.getTree = function () {
	return this.Tree;
};
TreeNode.prototype.getNodes = function () {
	if (this.Nodes == null) {
		this.Nodes = new Collection();
	}
	return this.Nodes;
};
TreeNode.prototype.addNode = function (messageNode, tree) {
	if (messageNode._parent != null) {
		messageNode.remove(tree);
	}
	var cArray14 = this.getNodes();
	cArray14.insertElement(messageNode);
	messageNode.Data = messageNode;
	messageNode._parent = this;
	if (this.Tree != null) {
		var TreeElement = this.Tree;
		TreeElement.NextNodeTree = tree.getNextNodeTree1(this);
		try {
			tree.setMessageNode(messageNode);
		}
		finally {
			tree.NextNodeTree = null;
		}
	}
};
TreeNode.prototype.removeNode = function (messageNode, tree) {
	this.getNodes().removeElement(messageNode);
	if (this.Tree != null) {
		tree.removeMessageRecordNode(messageNode);
	}
};
TreeNode.prototype.remove = function (tree) {
	this._parent.removeNode(this, tree);
};
TreeNode.prototype.hasExpanded = function () {
	return this.hasExpanded;
};
TreeNode.prototype.refresh = function () {
	if (this.Tree != null) {
		this.Tree.refreshNode(this);
	}
};
TreeNode.prototype.getNextNode = function () {
	function getNextTreeNode(messageNode) {
		var parent = messageNode._parent;
		if (parent != null && parent.Expanded) {
			var next = parent.priviousElement;
			if (next == null) {
				next = getNextTreeNode(parent);
			}
			return next;
		}
		return null;
	}
	if (this.Expanded && this.Nodes != null) {
		var next = this.Nodes.firstNode;
		if (next != null) {
			return next;
		}
	}
	var next = this.priviousElement;
	if (next == null) {
		next = getNextTreeNode(this);
	}
	return next;
};
TreeNode.prototype.getNodesRecord = function () {
	if (this.Expanded && this.Nodes != null) {
		var NodesLastRecord = this.Nodes.LastRecord;
		if (NodesLastRecord != null) {
			var record17 = NodesLastRecord;
			record17 = record17.getNodesRecord();
			if (record17 != null) {
				return record17;
			} else {
				return NodesLastRecord;
			}
		}
	}
	return null;
};
TreeNode.prototype.getPrevNode = function () {
	var record17 = this.previous;
	if (record17 == null) {
		record17 = this._parent;
	} else {
		if (record17.Expanded) {
			var NodesLastRecord = record17.getNodesRecord();
			if (NodesLastRecord != null) {
				record17 = NodesLastRecord;
			}
		}
	}
	return record17;
};
function DefaultTreeNode(label) {

     //alert(label+"    label");
	this.idd = addId();
	this.saturnClass = "DefaultTreeNode";
	this.Label = label;
	
	//alert(this.Label+"Label");
	this.Path = null;
}
DefaultTreeNode.prototype = new TreeNode();
DefaultTreeNode.prototype.getLabel = function () {
	return this.Label;
};
DefaultTreeNode.prototype.setLabel = function (label) {
	this.Label = label;
};
DefaultTreeNode.prototype.getPath = function () {
	return this.Path;
};
DefaultTreeNode.prototype.setPath = function (path) {
	if (path.length > 0 && path.charAt(0) == "/") {
		path = __CONTEXT_PATH + path;
	}
	this.Path = path;
};
saturnJspTag.TreeComponent = Class.create();
saturnJspTag.TreeComponent.prototype = Object.extend(new saturnJspTag.Base(), {initialize:function (id) {
	
	//alert("START TREE");
	
	this.TreeElement = document.getElementById(id);
	
	var TopNodeTree = new DefaultTreeNode();
	
	
	
	
	TopNodeTree.Tree = this.TreeElement;
	
	TopNodeTree.visible = true;
	TopNodeTree.Label = "TOP_NODE";
	this.TreeElement.TopNode = TopNodeTree;
	
	//alert(this.TreeElement.TopNode +"   jingenStart");
	
	this.TreeElement.draggable = false;
	this.TreeElement.CurrentNode = null;
	this.TreeElement.scrollInterval = 0;
	this.TreeElement.Target = null;
	this.TreeElement.HighlightSelection = true;
	this.TreeElement.PreferenceSetting = getPreferenceSetting("__Tree_LeftPadding");
	if (!(this.TreeElement.PreferenceSetting >= 0)) {
		this.TreeElement.PreferenceSetting = 0;
	}
	this.setDraggable(false);
}, activate:function (tree) {
 
   // alert(tree+"     actice:");

	if (!this.TreeElement.uMap02) {
		this.init(tree);
		this.getFirstLevelNodes(tree);
		this.TreeElement.uMap02 = true;
		this.TreeElement.TopNode.setExpanded(true, tree);
		tree.setScrollTop();
	}
}, destroy:function () {
	this.TreeElement.CurrentNode = null;
	this.TreeElement.parentNode1 = null;
	this.TreeElement.messagenode1 = null;
	this.TreeElement.TopNode.destroy();
	this.TreeElement.cursor02 = null;
	this.TreeElement.TrElement10 = null;
	this.TreeElement.TbodyElement4 = null;
}, init:function (tree) {
	this.TreeElement.style.overflow = "auto";
	this.TreeElement.innerHTML = "<TABLE><TBODY></TBODY></TABLE>";
	var TableElement = this.TreeElement.firstChild;
	TableElement.cellPadding = 0;
	TableElement.cellSpacing = 0;
	TableElement.style.width = "100%";
	this.TreeElement.TbodyElement4 = TableElement.tBodies[0];
	var ButtonElement = document.createElement("IMG");
	ButtonElement.className = "TreeNodeButton";
	ButtonElement.style.marginLeft = 4;
	ButtonElement.style.marginRight = 4;
	var TdElement = document.createElement("TD");
	var TrElement = document.createElement("TR");
	TdElement.className = "TreeNode";
	TdElement.style.width = "100%";
	TdElement.style.whiteSpace = "nowrap";
	TdElement.appendChild(ButtonElement);
	TrElement.appendChild(TdElement);
	this.TreeElement.TrElement10 = TrElement;
	var TreeElement = this.TreeElement;
	EventManager.addSystemEvent(this.TreeElement, "onmousedown", function (event) {
		tree.onmousedownTree(TreeElement, event, tree);
		event.cancelBubble = true;
	});
	EventManager.addSystemEvent(this.TreeElement, "onmousemove", function (event) {
		tree.onmousemoveTree(TreeElement, event, tree);
	});
	EventManager.addSystemEvent(this.TreeElement, "onmouseup", function (event) {
		tree.onmouseupTree(TreeElement, event, tree);
	});
	EventManager.addSystemEvent(this.TreeElement, "onclick", function (event) {
		tree.onclickTree(TreeElement, event, tree);
	});
	EventManager.addSystemEvent(this.TreeElement, "ondblclick", function (event) {
		tree.ondblclickTree(TreeElement, event, tree);
	});
}, isDraggable:function () {
	return this.TreeElement.draggable;
}, setDraggable:function (Draggable) {
	this.TreeElement.draggable = Draggable;
}, getTopNode:function () {
	return this.TreeElement.TopNode;
}, addRootNode:function (messageNode) {
	this.TreeElement.TopNode.addNode(messageNode);
}, getNextNodeTree1:function (messageNode) {
	function getNextTreeNode(messageNode) {
		var parent = messageNode._parent;
		if (parent != null && parent.Expanded) {
			var next = parent.priviousElement;
			if (next == null) {
				next = getNextTreeNode(parent);
			}
			return next;
		}
		return null;
	}
	var next = messageNode.priviousElement;
	if (next == null) {
		next = getNextTreeNode(messageNode);
	}
	return next;
}, setMessageNode:function (messageNode) {
	this.insertRecordTree1(messageNode);
	this.setMessageNodeForTd(messageNode);
	if (this.TreeElement.CurrentNode == null) {
		this.setCurrentNode(messageNode);
	}
	if (this.TreeElement.uMap02) {
		this.refreshNode(messageNode._parent);
	}
}, insertRecordTree1:function (messageNode) {
	messageNode.Tree = this.TreeElement;
	fireSaturnEvent(this.TreeElement, "onInitNode", [this.TreeElement, messageNode]);
	if (messageNode.Nodes != null) {
		var spacialObj = messageNode.Nodes.firstNode;
		while (spacialObj != null) {
			this.insertRecordTree1(spacialObj.Data);
			spacialObj = spacialObj.priviousElement;
		}
	}
}, removeMessageRecordNode:function (messageNode) {
	this.removeMessageNodeAndParentNode(messageNode);
	this.removeRecordTree1(messageNode);
}, removeRecord:function (messageNode) {
	if (messageNode.Nodes != null) {
		var spacialObj = messageNode.Nodes.firstNode;
		while (spacialObj != null) {
			this.removeRecordTree1(spacialObj.Data);
			spacialObj = spacialObj.priviousElement;
		}
	}
	messageNode.CurrentCell = null;
	messageNode.Tree = null;
}, setTreeNodeCheckBox:function (TdElement, messageNode) {
	var cflag16 = (messageNode.getIcon() != null || messageNode.getExpandedIcon() != null);
	if (TdElement.treeTdFlag == cflag16 && TdElement.Checkable == messageNode.Checkable) {
		return;
	}
	for (var i = TdElement.childNodes.length - 1; i >= 1; i--) {
		TdElement.removeChild(TdElement.childNodes[i]);
	}
	if (messageNode.Checkable) {
		var checkbox = document.createElement("INPUT");
		checkbox.type = "checkbox";
		checkbox.saturnClass = "TreeNodeCheckBox";
		checkbox.messagenode = messageNode;
		TdElement.appendChild(checkbox);
	}
	if (cflag16) {
		var IMGElement4 = document.createElement("IMG");
		IMGElement4.saturnClass = "TreeNodeIcon";
		if (browserType == browserType1) {
			IMGElement4.unselectable = true;
		} else {
			IMGElement4.style.MozUserSelect = "none";
		}
		IMGElement4.style.marginRight = 4;
		TdElement.appendChild(IMGElement4);
	}
	var label = document.createElement("LABEL");
	label.saturnClass = "TreeNodeLabel";
	if (browserType == browserType1) {
		label.unselectable = true;
	} else {
		label.style.MozUserSelect = "none";
	}
	TdElement.appendChild(label);
	var ButtonElement = TdElement.firstChild;
	ButtonElement.saturnClass = "TreeNodeButton";
	TdElement.treeTdFlag = cflag16;
	TdElement.Checkable = messageNode.Checkable;
}, setMessageNodeForTd:function (messageNode) {
	var _parent = messageNode._parent;
	if (_parent.visible == true && _parent.Expanded) {
		var firstRow = null;
		var NextNodeTree1 = this.TreeElement.NextNodeTree;
		if (NextNodeTree1 != null && NextNodeTree1.CurrentCell) {
			firstRow = NextNodeTree1.CurrentCell.parentNode;
		}
		var TrElement = this.TreeElement.TrElement10.cloneNode(true);
		TrElement.messagenode = messageNode;
		var TdElement = TrElement.firstChild;
		TdElement.saturnClass = "DefaultTreeNode";
		if (browserType == browserType1) {
			TdElement.unselectable = true;
		} else {
			TdElement.style.MozUserSelect = "none";
		}
		if (firstRow == null) {
			this.TreeElement.TbodyElement4.appendChild(TrElement);
		} else {
			this.TreeElement.TbodyElement4.insertBefore(TrElement, firstRow);
		}
		messageNode.CurrentCell = TdElement;
		messageNode.visible = true;
		this.refreshNode(messageNode);
		if (messageNode.Expanded) {
			if (messageNode.Nodes != null) {
				var spacialObj = messageNode.Nodes.firstNode;
				while (spacialObj != null) {
					this.setMessageNodeForTd(spacialObj.Data);
					spacialObj = spacialObj.priviousElement;
				}
			}
		}
	}
}, removeMessageNodeAndParentNode:function (messageNode) {
	if (messageNode.Expanded) {
		if (messageNode.Nodes != null) {
			var spacialObj = messageNode.Nodes.firstNode;
			while (spacialObj != null) {
				this.removeMessageNodeAndParentNode(spacialObj.Data);
				spacialObj = spacialObj.priviousElement;
			}
		}
	}
	if (this.TreeElement.CurrentNode == messageNode) {
		var curNodePreSibling = null;
		var spacialObj = messageNode._parent.Nodes.findElement(messageNode);
		if (spacialObj != null) {
			if (spacialObj.priviousElement != null) {
				curNodePreSibling = spacialObj.priviousElement.Data;
			} else {
				if (spacialObj.previous != null) {
					curNodePreSibling = spacialObj.previous.Data;
				} else {
					if (messageNode._parent != this.TreeElement.TopNode) {
						curNodePreSibling = messageNode._parent;
					}
				}
			}
			if (curNodePreSibling != null) {
				this.setCurrentNode(curNodePreSibling);
			}
		}
	}
	this.TreeElement.TbodyElement4.removeChild(messageNode.CurrentCell.parentNode);
	messageNode.CurrentCell = null;
	messageNode.visible = false;
}, refreshNode:function (messageNode) {
	var TdElement = messageNode.CurrentCell;
	if (!TdElement) {
		return;
	}
	this.setTreeNodeCheckBox(TdElement, messageNode);
	TdElement.style.paddingLeft = this.TreeElement.PreferenceSetting + (messageNode.getLevel() - 1) * 6;
	var ButtonElement = TdElement.firstChild;
	if (messageNode.HasChild || (messageNode.Nodes != null && messageNode.Nodes.size() > 0)) {
		if (messageNode.Expanded) {
		//	ButtonElement.src = __SKIN_PATH + "/tree_collapse.gif";
			//ButtonElement.src = __SKIN_PATH + "/minus2.gif";
		} else {
		//	ButtonElement.src = __SKIN_PATH + "/tree_expand.gif";
			//ButtonElement.src = __SKIN_PATH + "/plus3.gif";
		}
	} else {
		//ButtonElement.src = __SKIN_PATH + "/tree_nochild.gif";
		//ButtonElement.src = __SKIN_PATH + "/line3.gif";
	}
	var IMGElement7, checkbox, label;
	var childNodes = TdElement.childNodes;
	for (var i = 1; i < childNodes.length; i++) {
		var spacialObj = childNodes[i];
		switch (spacialObj.saturnClass) {
		  case "TreeNodeCheckBox":
			checkbox = spacialObj;
			break;
		  case "TreeNodeIcon":
			IMGElement7 = spacialObj;
			break;
		  case "TreeNodeLabel":
			label = spacialObj;
			break;
		}
	}
	if (label != null) {
		var text = messageNode.getLabel();
		if (this.TreeElement._onRefreshNode == null || fireSaturnEvent(this.TreeElement, "onRefreshNode", [this.TreeElement, label, text, messageNode])) {
			label.innerText = text;
		}
	}
	if (checkbox != null) {
		checkbox.checked = messageNode.isChecked();
	}
	if (IMGElement7 != null) {
		IMGElement7.src = (messageNode.Expanded) ? messageNode.getExpandedIcon() : messageNode.getIcon();
	}
}, ExpandedNode:function (messageNode) {
}, expandNode:function (messageNode) {
	if (messageNode.Expanded || (!messageNode.HasChild && (messageNode.Nodes == null || messageNode.Nodes.size() == 0))) {
		return;
	}
	try {
		var fireArray = fireSaturnEvent(this.TreeElement, "beforeExpandNode", [this.TreeElement, messageNode]);
		if (fireArray != null) {
			throw fireArray;
		}
		this.ExpandedNode(messageNode);
		messageNode.setExpandedTreeNode(true);
		var hasChild = false;
		var cArray14 = messageNode.Nodes;
		if (cArray14 != null) {
			this.TreeElement.NextNodeTree = this.getNextNodeTree1(messageNode);
			try {
				var spacialObj = cArray14.firstNode;
				while (spacialObj != null) {
					var childNode = spacialObj.Data;
					this.setMessageNodeForTd(childNode);
					hasChild = true;
					spacialObj = spacialObj.priviousElement;
				}
			}
			finally {
				this.TreeElement.NextNodeTree = null;
			}
		}
		messageNode.HasChild = hasChild;
		this.refreshNode(messageNode);
		fireSaturnEvent(this.TreeElement, "afterExpandNode", [this.TreeElement, messageNode]);
	}
	catch (e) {
		outputExceptionMessage(e);
	}
}, collapseNode:function (messageNode) {
	if (!messageNode.Expanded) {
		return;
	}
	try {
		var fireArray = fireSaturnEvent(this.TreeElement, "beforeCollapseNode", [this.TreeElement, messageNode]);
		if (fireArray != null) {
			throw fireArray;
		}
		var CurrentNode1 = this.TreeElement.CurrentNode;
		if (CurrentNode1 != null) {
			do {
				CurrentNode1 = CurrentNode1._parent;
				if (CurrentNode1 == messageNode) {
					this.setCurrentNode(messageNode);
					break;
				}
			} while (CurrentNode1 != null && CurrentNode1 != this.TreeElement.TopNode);
		}
		messageNode.setExpandedTreeNode(false);
		var cArray14 = messageNode.Nodes;
		if (cArray14 != null) {
			var spacialObj = cArray14.firstNode;
			while (spacialObj != null) {
				var childNode = spacialObj.Data;
				this.removeMessageNodeAndParentNode(childNode);
				spacialObj = spacialObj.priviousElement;
			}
		}
		this.refreshNode(messageNode);
		fireSaturnEvent(this.TreeElement, "afterCollapseNode", [this.TreeElement, messageNode]);
	}
	catch (e) {
		outputExceptionMessage(e);
	}
}, getCurrentNode:function (messageNode) {
	return this.TreeElement.CurrentNode;
}, hasMessageNode:function (messageNode) {
	return true;
}, setScrollTop:function () {
	if (!this.TreeElement.uMap02) {
		return;
	}
	if (this.TreeElement.CurrentNode == null) {
		return;
	}
	var TdElement = this.TreeElement.CurrentNode.CurrentCell;
	var TrElement = null;
	if (TdElement != null) {
		TrElement = TdElement.parentNode;
	}
	if (TrElement == null) {
		return;
	}
	var absolutePosition = getAbsolutePosition(TrElement, this.TreeElement);
	var top = absolutePosition[1];
	var bottom = top + TrElement.offsetHeight;
	var scrollTop = this.TreeElement.scrollTop;
	var topAndWidth = scrollTop + this.TreeElement.clientHeight;
	if (top < scrollTop) {
		this.TreeElement.scrollTop = top;
	} else {
		if (bottom > topAndWidth) {
			this.TreeElement.scrollTop = this.TreeElement.scrollTop + (bottom - topAndWidth);
		}
	}
}, setCurrentNode:function (messageNode) {
	try {
		if (messageNode == this.TreeElement.CurrentNode) {
			return;
		}
		var fireArray = fireSaturnEvent(this.TreeElement, "beforeCurrentChange", [this.TreeElement, messageNode]);
		if (fireArray != null) {
			throw fireArray;
		}
		if (!this.hasMessageNode(messageNode)) {
			throw "abort";
		}
		if (this.TreeElement.HighlightSelection) {
			if (this.TreeElement.CurrentNode != null) {
				var TdElement = this.TreeElement.CurrentNode.CurrentCell;
				if (TdElement != null) {
					TdElement.className = "TreeTreeNode";
				}
			}
			if (messageNode != null) {
				var TdElement = messageNode.CurrentCell;
				if (TdElement != null) {
					TdElement.className = "TreeCurrentTreeNode";
				}
			}
		}
		this.TreeElement.CurrentNode = messageNode;
		fireSaturnEvent(this.TreeElement, "afterCurrentChange", [this.TreeElement, messageNode]);
		this.setScrollTop();
	}
	catch (e) {
		outputExceptionMessage(e);
	}
}, getCursor:function (curCell) {
	var TrElement = document.createElement("TR");
	var TdElement = curCell.cloneNode(true);
	TdElement.firstChild.parentNode.removeChild(TdElement.firstChild);
	TdElement.style.paddingLeft = 0;
	TrElement.appendChild(TdElement);
	var TbodyElement = document.createElement("TBODY");
	TbodyElement.appendChild(TrElement);
	cursor = document.createElement("TABLE");
	cursor.appendChild(TbodyElement);
	cursor.cellPadding = 0;
	cursor.cellSpacing = 0;
	cursor.className = "TreeDraggingCursor";
	cursor.style.position = "absolute";
	setComponentVisible(cursor, false);
	document.body.appendChild(cursor);
	return cursor;
}, initDraggingTarget:function (messageNode) {
	if (this.TreeElement.messagenode1 != null) {
		var TdElement = this.TreeElement.messagenode1.CurrentCell;
		if (TdElement != null) {
			TdElement.className = "TreeNode";
		}
	}
	var cflag9 = true;
	var parentNode = messageNode;
	while (parentNode) {
		if (this.TreeElement.parentNode1 == parentNode) {
			cflag9 = false;
			break;
		}
		parentNode = parentNode._parent;
	}
	if (cflag9) {
		this.TreeElement.messagenode1 = messageNode;
		if (messageNode != null) {
			var TdElement = messageNode.CurrentCell;
			if (TdElement != null) {
				TdElement.className = "DraggingTarget";
			}
		}
	} else {
		this.TreeElement.messagenode1 = null;
	}
}, hasChildNodeForDraggable:function (parentNode2, messagenode2) {
	return true;
}, hasChildNodeForExpand:function (parentNode2, messagenode2) {
}, setDoubleScroll:function (x, y) {
	this.TreeElement.scrollLeft += x * 2;
	this.TreeElement.scrollTop += y * 2;
}, onmousedownTree:function (TreeElement, event, tree) {
	Element_onFocus(TreeElement);
	var target;
	if (browserType == browserType1) {
		target = event.srcElement;
	} else {
		target = event.target;
	}
	if (target.saturnClass != "TreeNodeButton") {
		var TdElement = null;
		var spacialObj = target;
		while (spacialObj != null) {
			if (spacialObj.saturnClass == "DefaultTreeNode") {
				TdElement = spacialObj;
				break;
			}
			spacialObj = spacialObj.parentNode;
		}
		if (TdElement != null) {
			var TrElement = TdElement.parentNode;
			var messageNode = TrElement.messagenode;
			tree.setCurrentNode(messageNode);
			if (TreeElement.CurrentNode != messageNode) {
				return;
			}
			TreeElement.parentNode1 = messageNode;
			TreeElement.$Zm = true;
			var x, y;
			if (browserType == browserType1) {
				x = event.clientX + document.body.scrollLeft;
				y = event.clientY + document.body.scrollTop;
			} else {
				x = event.pageX;
				y = event.pageY;
			}
			TreeElement.positionX = x;
			TreeElement.positionY = y;
		}
	}
}, onmousemoveTree:function (TreeElement, event, tree) {
	var target;
	if (browserType == browserType1) {
		target = event.srcElement;
	} else {
		target = event.target;
	}
	var x, y;
	if (browserType == browserType1) {
		x = event.clientX + document.body.scrollLeft;
		y = event.clientY + document.body.scrollTop;
	} else {
		x = event.pageX;
		y = event.pageY;
	}
	if (TreeElement.draggable && !TreeElement.setCursor && TreeElement.$Zm) {
		var parentNode2 = TreeElement.parentNode1;
		if (TreeElement._onDragStart == null || fireSaturnEvent(TreeElement, "onDragStart", [TreeElement, parentNode2])) {
			if (Math.abs(x - TreeElement.positionX) > 5 || Math.abs(y - TreeElement.positionY) > 5) {
				if (parentNode2 != null) {
					TreeElement.setCursor = true;
					var cursor = tree.getCursor(parentNode2.CurrentCell);
					TreeElement.cursor02 = cursor;
					setComponentVisible(cursor, true);
					TreeElement.setCapture(true);
				}
			}
		}
	}
	if (TreeElement.setCursor) {
		var cursor = TreeElement.cursor02;
		cursor.style.left = x - (cursor.offsetWidth / 2);
		cursor.style.top = y - (cursor.offsetHeight / 2);
		var absolutePosition = getAbsolutePosition(TreeElement);
		var rows = TreeElement.TbodyElement4.rows;
		var doubleScrollX = 0, doubleScrollY = 0;
		if (x < absolutePosition[0]) {
			doubleScrollX = -1;
		} else {
			if (x > (absolutePosition[0] + TreeElement.offsetWidth)) {
				doubleScrollX = 1;
			}
		}
		if (y < absolutePosition[1]) {
			doubleScrollY = -1;
		} else {
			if (y > (absolutePosition[1] + TreeElement.offsetHeight)) {
				doubleScrollY = 1;
			}
		}
		if (doubleScrollX == 0 && doubleScrollY == 0) {
			clearInterval(TreeElement.scrollInterval);
			TreeElement.scrollInterval = 0;
			var TableElement = TreeElement.TbodyElement4.parentNode;
			absolutePosition = getAbsolutePosition(TableElement);
			var spacialObj = ((y - absolutePosition[1]) / TableElement.offsetHeight) * rows.length;
			if (spacialObj >= 0 && spacialObj < rows.length) {
				var TrElement = rows[spacialObj];
				var parentNode2 = TreeElement.parentNode1;
				var messagenode2 = TrElement.messagenode;
				var dragSymbel = false;
				if (TreeElement._onDragOver == null && tree.hasChildNodeForDraggable(parentNode2, messagenode2)) {
					dragSymbel = true;
				} else {
					if (fireSaturnEvent(TreeElement, "onDragOver", [TreeElement, parentNode2, messagenode2])) {
						dragSymbel = true;
					}
				}
				if (dragSymbel) {
					tree.initDraggingTarget(messagenode2);
				} else {
					tree.initDraggingTarget(null);
				}
			}
		} else {
			tree.initDraggingTarget(null);
			if (TreeElement.scrollInterval == 0) {
				TreeElement.scrollInterval = setInterval("document.getElementById(\"" + TreeElement.id + "\").setDoubleScroll(" + doubleScrollX + ", " + doubleScrollY + ")", 10);
			}
		}
	}
}, onmouseupTree:function (TreeElement, event, tree) {
	var target;
	if (browserType == browserType1) {
		target = event.srcElement;
	} else {
		target = event.target;
	}
	TreeElement.$Zm = false;
	if (TreeElement.setCursor) {
		clearInterval(TreeElement.scrollInterval);
		TreeElement.scrollInterval = 0;
		if (browserType == browserType1) {
			TreeElement.releaseCapture();
		} else {
		}
		if (TreeElement.cursor02 != null) {
			TreeElement.cursor02.parentNode.removeChild(TreeElement.cursor02);
		}
		TreeElement.cursor02 = null;
		TreeElement.setCursor = false;
		var parentNode2 = TreeElement.parentNode1;
		var messagenode2 = TreeElement.messagenode1;
		if (parentNode2 != null && messagenode2 != null) {
			if (TreeElement._onDragEnd == null || fireSaturnEvent(TreeElement, "onDragEnd", [TreeElement, parentNode2, messagenode2])) {
				tree.hasChildNodeForExpand(parentNode2, messagenode2);
				tree.expandNode(messagenode2);
				TreeElement.CurrentNode = null;
				messagenode2.addNode(parentNode2);
				tree.setCurrentNode(parentNode2);
			}
		}
		tree.initDraggingTarget(null);
	}
}, onclickTree:function (TreeElement, event, tree) {

 


//validate(TreeElement, event, tree);
//tree.a(TreeElement, event, tree);
//showLoadingDiv();//放到了单击点节名的时候
	var target;
	if (browserType == browserType1) {
	 
		target = event.srcElement;
		
		
	} else {
		target = event.target;
	}
	if (target.saturnClass == "TreeNodeCheckBox") {
	   
	      
		var TrElement = target.parentNode.parentNode;
		var messageNode = TrElement.messagenode;
		messageNode.setChecked(target.checked);
		fireSaturnEvent(TreeElement, "onCheckStateChanged", [TreeElement, messageNode]);
	} else {
	
	 
	
		if (target.saturnClass == "TreeNodeButton") {
		
		
		 // alert("javaohao");
			var TrElement = target.parentNode.parentNode;
			var messageNode = TrElement.messagenode;
			var TreeElement = messageNode.Tree;
			if (messageNode.Expanded) {
				tree.collapseNode(messageNode);
			} else {

				tree.expandNode(messageNode);
			}
			event.cancelBubble = true;
		} else {
		
		   
		    //alert("danjijiedian");
		    showLoadingDiv();
			var TdElement = null;
			var spacialObj = target;
			while (spacialObj != null) {
				if (spacialObj.saturnClass == "DefaultTreeNode") {
					TdElement = spacialObj;
					break;
				}
				spacialObj = spacialObj.parentNode;
			}
			if (TdElement != null) {
				var TrElement = TdElement.parentNode;
				var messageNode = TrElement.messagenode;
				if (messageNode.Path != null) {
					if (TreeElement.Target == null) {
					 
						window.open(messageNode.Path, "_self");
						 window.setTimeout("hideLoadingDiv()", 1000);
					} else {
					
					  //alert(messageNode.Id);
						//showLoadingDiv()
					//fnUserLogin();
					//	document.frames[TreeElement.Target].location.reload()
					   window.setTimeout("hideLoadingDiv()", 500);
					   //alert("dddddddddd");
					window.open(messageNode.Path, TreeElement.Target);
						//hideLoadingDiv();
					document.frames[TreeElement.Target].location = messageNode.Path;
					//document.frames[TreeElement.Target].location.reload()
					//document.frames[TreeElement.Target].location.reload()
					//setTimeout("tree.reloadJsp(\"" + TreeElement.Target + "\")",100);
					}
				}
					else{ window.setTimeout("hideLoadingDiv()", 500);}//TODO:陈岩 这句是判断没有path也去掉延时框加上的
				fireSaturnEvent(TreeElement, "onClick", [TreeElement, messageNode]);
			}
		}
	}
	 window.setTimeout("hideLoadingDiv()", 500);
},
 reloadJsp:function (target){
 	document.frames[target].location.reload();
 },

 ondblclickTree:function (TreeElement, event, tree) {
	var target;
	if (browserType == browserType1) {
		target = event.srcElement;
	} else {
		target = event.target;
	}
	var TdElement = null;
	var spacialObj = target;
	while (spacialObj != null) {
		if (spacialObj.saturnClass == "DefaultTreeNode") {
			TdElement = spacialObj;
			break;
		}
		spacialObj = spacialObj.parentNode;
	}
	if (TdElement != null) {
		var TrElement = TdElement.parentNode;
		var messageNode = TrElement.messagenode;
		if (messageNode.Expanded) {
			tree.collapseNode(messageNode);
		} else {
			tree.expandNode(messageNode);
		}
		fireSaturnEvent(TreeElement, "onDblClick", [TreeElement, messageNode]);
	}
}, getFirstLevelNodes:function (tree) {
	if (this.TreeElement.hasXMLData) {
		return;
	}
	this.TreeElement.hasXMLData = true;
	var xmlNode = document.getElementById("__" + this.TreeElement.id);
	if (xmlNode != null) {
		var firstLevelNodes;
		if (browserType == browserType1) {
			firstLevelNodes = xmlNode.documentElement;
		} else {
			firstLevelNodes = xmlNode.getElementsByTagName("nodes")[0];
		}
		if (firstLevelNodes != null) {
			this.outputTreeNode(this.TreeElement.TopNode, firstLevelNodes, tree);
		}
	}
}, outputTreeNode:function (topElement, rootNode, tree, nodeLevel) {
	var childNodesArray = rootNode.childNodes;
	for (var i = 0; i < childNodesArray.length; i++) {
		var childNode3 = childNodesArray[i];
		if (browserType == browserType1 || childNode3.nodeName.charAt(0) != "#") {
			var defaultTreeNode1 = new DefaultTreeNode(childNode3.getAttribute("label"));
			defaultTreeNode1.setExpandedTreeNode(parseBoolean(childNode3.getAttribute("expanded")));
			defaultTreeNode1.HasChild = parseBoolean(childNode3.getAttribute("hasChild"));
			defaultTreeNode1.Icon = childNode3.getAttribute("icon");
			defaultTreeNode1.Id = childNode3.getAttribute("id");//TODO:chenyan 加上了树节点的id
			defaultTreeNode1.ExpandedIcon = childNode3.getAttribute("expandedIcon");
			defaultTreeNode1.Checkable = parseBoolean(childNode3.getAttribute("checkable"));
			defaultTreeNode1.Checked = parseBoolean(childNode3.getAttribute("checked"));
			defaultTreeNode1.Path = childNode3.getAttribute("path");
			defaultTreeNode1.tag = childNode3.getAttribute("tag");
			this.outputTreeNode(defaultTreeNode1, childNode3, tree, nodeLevel + 1);
			topElement.addNode(defaultTreeNode1, tree);
		}
	}
}, getTarget:function () {
	return this.TreeElement.Target;
}, setTarget:function (target) {
	this.TreeElement.Target = target;
}, isHighlightSelection:function () {
	return this.TreeElement.HighlightSelection;
}, setHighlightSelection:function (highlightSelection) {
	this.TreeElement.HighlightSelection = highlightSelection;
}, getAllCheckedNodes:function () {
	function checkEveryNode(parentNode, cArray14) {
		if (parentNode.Nodes != null) {
			var spacialObj = parentNode.Nodes.firstNode;
			while (spacialObj != null) {
				var messageNode = spacialObj.Data;
				if (messageNode.isChecked()) {
					cArray14.push(messageNode);
				}
				checkEveryNode(messageNode, cArray14);
				spacialObj = spacialObj.priviousElement;
			}
		}
		return null;
	}
	var cArray14 = new Array();
	checkEveryNode(this.TreeElement.TopNode, cArray14);
	return cArray14;
}, clearAllCheckedState:function () {
	var cArray14 = this.getAllCheckedNodes();
	for (var i = 0; i < cArray14.length; i++) {
		var messageNode = cArray14[i];
		messageNode.setChecked(false);
		messageNode.refresh();
	}
},




/**

c:function (TreeElement, event, tree) {
var target;
	
	if (browserType == browserType1) {
		target = event.srcElement;
	} else {
		target = event.target;
	}
	if (target.saturnClass == "TreeNodeCheckBox") {
		var TrElement = target.parentNode.parentNode;
		var messageNode = TrElement.messagenode;
		messageNode.setChecked(target.checked);
		fireSaturnEvent(TreeElement, "onCheckStateChanged", [TreeElement, messageNode]);
	} else {
		if (target.saturnClass == "TreeNodeButton") {
			var TrElement = target.parentNode.parentNode;
			var messageNode = TrElement.messagenode;
			var TreeElement = messageNode.Tree;
			if (messageNode.Expanded) {
				tree.collapseNode(messageNode);
			} else {

				tree.expandNode(messageNode);
			}
			event.cancelBubble = true;
		} else {
			var TdElement = null;
			var spacialObj = target;
			while (spacialObj != null) {
				if (spacialObj.saturnClass == "DefaultTreeNode") {
					TdElement = spacialObj;
					break;
				}
				spacialObj = spacialObj.parentNode;
			}
			if (TdElement != null) {
				var TrElement = TdElement.parentNode;
				var messageNode = TrElement.messagenode;
				if (messageNode.Path != null) {
					if (TreeElement.Target == null) {
						window.open(messageNode.Path, "_self");
					} else {
					//showLoadingDiv()
					//fnUserLogin();
					//	document.frames[TreeElement.Target].location.reload()
					window.open(messageNode.Path, TreeElement.Target);
					
					//	hideLoadingDiv();
					 //window.setTimeout("hideLoadingDiv()", 1000);
					
					document.frames[TreeElement.Target].location = messageNode.Path;
					
					
					//document.frames[TreeElement.Target].location.reload()
					//document.frames[TreeElement.Target].location.reload()
					//setTimeout("tree.reloadJsp(\"" + TreeElement.Target + "\")",100);
					}
				}
				
				fireSaturnEvent(TreeElement, "onClick", [TreeElement, messageNode]);
			}
		}
	}
	
},**/










/**
a:function(TreeElement, event, tree){
 showLoadingDiv();
createXMLHttpRequest();
var url = "f.jsp";
xmlHttp.open("GET",url,true);
xmlHttp.onreadystatechange = 
//callback;
tree.c(TreeElement, event, tree);
/**
 if(xmlHttp.readyState == 4){
  showLoadingDiv();
 
 if(xmlHttp.status == 200){

}else{
                                alert("error: HTTP-" + xmlHttp.status);
   }
 }	
  else{
  
  //alert("信息还未返回");
  }
; 
 xmlHttp.send(null);
 
 }
,

**/

/**
b:function(TreeElement, event, tree){

alert("www");
},
**/


















 onKeyDown:function (event) {
	switch (event.keyCode) {
	  case 37:
		if (this.TreeElement.CurrentNode != null) {
			this.collapseNode(this.TreeElement.CurrentNode);
		}
		event.returnValue = false;
		break;
	  case 39:
		if (this.TreeElement.CurrentNode != null) {
			this.expandNode(this.TreeElement.CurrentNode);
		}
		event.returnValue = false;
		break;
	  case 38:
		if (this.TreeElement.CurrentNode != null) {
			var TdElement = this.TreeElement.CurrentNode.CurrentCell;
			if (TdElement != null) {
				var Sibling = TdElement.parentNode.previousSibling;
				if (Sibling != null) {
					this.setCurrentNode(Sibling.messagenode);
				}
			}
		}
		event.returnValue = false;
		break;
	  case 40:
		if (this.TreeElement.CurrentNode != null) {
			var TdElement = this.TreeElement.CurrentNode.CurrentCell;
			if (TdElement != null) {
				var Sibling = TdElement.parentNode.nextSibling;
				if (Sibling != null) {
					this.setCurrentNode(Sibling.messagenode);
				}
			}
		}
		event.returnValue = false;
		break;
	}
}});





/**
function callback()
{

 if(xmlHttp.readyState == 4){
  showLoadingDiv();
 
 if(xmlHttp.status == 200){
   alert("chengle");
}else{
                                alert("error: HTTP-" + xmlHttp.status);
   }
 }	
  else{
  
  alert("信息还未返回");
  }


}

**/



function fnUserLogin(){	
var param = "" ;
  var url = urlpath + "/loginAction.do?request=PWDLOGIN";
 remoteCallV2(url, "post", param, onhandleResult);
 //hideLoadingDiv();
}
function onhandleResult(res)
{
	
  if (!res.success){
    openErrordia(res.text);
    //FmLogon.image.src=urlpath + "/vercodeservlet";
    FmLogon.reset.click();
    return false;
  } else {
    window.open(urlpath + "/mainFrameAction.do", '_self');
  }
}
function remoteCallV2(url, method, param, callback){
  REMOTE_URL = url;
  REMOTE_METHOD = method;
  REMOTE_PARAM = param;
  REMOTE_CALLBACK = callback;
 if (event != null){
   if (event.srcElement != null)
   event.srcElement.disabled = true;
 }
  try{
    if (callback != null){
      showLoadingDiv();
      //window.setTimeout("doRemoteCall()", 1);
      //window.setTimeout("hideLoadingDiv()", 1000);
       //window.setTimeout("onclickTree()", 1000);
     
    } else {
      return doRemoteCall();
    }
  } finally{
    if (event != null){
      if (event.srcElement != null)
        event.srcElement.disabled = false;
    }
  }
}

function showLoadingDiv(){
var div = document.getElementById("loadingdiv");
if (div) div.removeNode(true);
var sBG = '<div id="loadingdiv" style="position:absolute;top:0px;left:0px;width:100%;height:100%;background:url(' + urlpath + '/images/blank.gif)"><table border="1" bgcolor="white" id="loadingtable" bordercolor="#C0C0C0">\
<tr>\
<td align=right bordercolor=white>\
<img border="0" src="' + urlpath + '/images/loading.gif"></td>\
 <td aling=left bordercolor=white>正在提交请求，请稍等.....</td>\
 </tr>\
 </table></div>';
 var oDiv = document.body.insertAdjacentHTML("beforeEnd", sBG);
 middleIt('loadingtable');
 }
 function middleIt (_sId){
	var sClientWidth = parent ? parent.document.body.clientWidth : document.body.clientWidth;
   var sClientHeight = parent ? parent.document.body.clientHeight : document.body.clientHeight;
   var sScrollTop = parent ? parent.document.body.scrollTop : document.body.scrollTop;
   document.getElementById(_sId)['style']['display'] = '';
   document.getElementById(_sId)['style']['position'] = "absolute";
  // document.getElementById(_sId)['style']['left'] = (document.body.clientWidth / 2) - (document.getElementById(_sId).offsetWidth / 2);
 //  var sTop = -80 + (sClientHeight / 2 + sScrollTop) - (document.getElementById(_sId).offsetHeight / 2);
   //document.getElementById(_sId)['style']['top'] = sTop > 0 ? sTop : (sClientHeight / 2 + sScrollTop) - (document.getElementById(_sId).offsetHeight / 2);
  document.getElementById(_sId)['style']['left'] = event.clientX;
  
  
   document.getElementById(_sId)['style']['top'] = event.clientY;

}
 function hideLoadingDiv()
 {
   var div = document.getElementById("loadingdiv");
   if (div) div.removeNode(true);
 }
 
 
 /**
 function createXMLHttpRequest(){
 
  if(window.ActiveXObject){
  xmlHttp = new ActiveXObject("Microsoft.XMLHTTP");
  }                
  if(window.XMLHttpRequest){
  xmlHttp = new XMLHttpRequest();
 if(xmlHttp.overrideMimeType)
{
xmlHttp.overrideMimeType("text/xml")
}
 }
 } 
 **/
 
 /**
function validate(TreeElement, event, tree){
//var a=TreeElement;
//var b=event;
//var c=tree;
createXMLHttpRequest();
var url = "f.jsp";
xmlHttp.open("GET",url,true);
xmlHttp.onreadystatechange = back;
 xmlHttp.send(null);
 }
 **/

/**
function back() {
 if(xmlHttp.readyState == 4){
 // showLoadingDiv()
 if(xmlHttp.status == 200){
	var target;
	
	if (browserType == browserType1) {
		target = event.srcElement;
		alert("1");
	} else {
	
		target = event.target;
	}
}else{
    alert("error: HTTP-" + xmlHttp.status);
   }
  }	
  else{
  
  alert("信息还未返回");
  }

/**
var target;
if (browserType == browserType1) {
		target = event.srcElement;
	} else {
		target = event.target;
	}
	if (target.saturnClass == "TreeNodeCheckBox") {
		var TrElement = target.parentNode.parentNode;
		var messageNode = TrElement.messagenode;
		messageNode.setChecked(target.checked);
		fireSaturnEvent(TreeElement, "onCheckStateChanged", [TreeElement, messageNode]);
	} else {
		if (target.saturnClass == "TreeNodeButton") {
			var TrElement = target.parentNode.parentNode;
			var messageNode = TrElement.messagenode;
			var TreeElement = messageNode.Tree;
			if (messageNode.Expanded) {
				tree.collapseNode(messageNode);
			} else {

				tree.expandNode(messageNode);
			}
			event.cancelBubble = true;
		} else {
			var TdElement = null;
			var spacialObj = target;
			while (spacialObj != null) {
				if (spacialObj.saturnClass == "DefaultTreeNode") {
					TdElement = spacialObj;
					break;
				}
				spacialObj = spacialObj.parentNode;
			}
			if (TdElement != null) {
				var TrElement = TdElement.parentNode;
				var messageNode = TrElement.messagenode;
				if (messageNode.Path != null) {
					if (TreeElement.Target == null) {
						window.open(messageNode.Path, "_self");
					} else {
					showLoadingDiv()
					
					//	document.frames[TreeElement.Target].location.reload()
					window.open(messageNode.Path, TreeElement.Target);
					
					
					 window.setTimeout("hideLoadingDiv()", 1000);
					
					document.frames[TreeElement.Target].location = messageNode.Path;
					
					
					//document.frames[TreeElement.Target].location.reload()
					//document.frames[TreeElement.Target].location.reload()
					//setTimeout("tree.reloadJsp(\"" + TreeElement.Target + "\")",100);
					}
				}
				
				fireSaturnEvent(TreeElement, "onClick", [TreeElement, messageNode]);
			}
		}
	}**/
	
//}

 
 
 
 
 


